Message ID | 1381769148-22400-5-git-send-email-ehabkost@redhat.com |
---|---|
State | New |
Headers | show |
diff --git a/savevm.c b/savevm.c index 16276e7..87773ad 100644 --- a/savevm.c +++ b/savevm.c @@ -1766,6 +1766,9 @@ void vmstate_save_state(QEMUFile *f, const VMStateDescription *vmsd, !field->field_exists(opaque, vmsd->version_id)) { continue; } + if (field->version_id > vmsd->version_id) { + continue; + } void *base_addr = opaque + field->offset; int i, n_elems = 1;
This will allow fields to have version_id > vmsd->version_id, to allow us to support loading data with higher version_id. This patch alone is not useful by itself, but it will be useful when introducing the max_version_id field to VMStateDescription. Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> --- savevm.c | 3 +++ 1 file changed, 3 insertions(+)