From patchwork Fri Aug 28 13:28:25 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Juan Quintela X-Patchwork-Id: 32375 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by bilbo.ozlabs.org (Postfix) with ESMTPS id 16BBFB7BA5 for ; Sat, 29 Aug 2009 00:23:00 +1000 (EST) Received: from localhost ([127.0.0.1]:52038 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mh2Cq-00076C-QT for incoming@patchwork.ozlabs.org; Fri, 28 Aug 2009 10:13:32 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Mh1Xz-0004tc-0v for qemu-devel@nongnu.org; Fri, 28 Aug 2009 09:31:19 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Mh1Xt-0004ki-DV for qemu-devel@nongnu.org; Fri, 28 Aug 2009 09:31:17 -0400 Received: from [199.232.76.173] (port=38622 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mh1Xs-0004k3-IR for qemu-devel@nongnu.org; Fri, 28 Aug 2009 09:31:12 -0400 Received: from mx1.redhat.com ([209.132.183.28]:13467) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1Mh1Xr-0004s1-VY for qemu-devel@nongnu.org; Fri, 28 Aug 2009 09:31:12 -0400 Received: from int-mx03.intmail.prod.int.phx2.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id n7SDVBjS007469 for ; Fri, 28 Aug 2009 09:31:11 -0400 Received: from localhost.localdomain (vpn2-8-216.ams2.redhat.com [10.36.8.216]) by int-mx03.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id n7SDUpnt030148; Fri, 28 Aug 2009 09:31:10 -0400 From: Juan Quintela To: qemu-devel@nongnu.org Date: Fri, 28 Aug 2009 15:28:25 +0200 Message-Id: <1d2a962f13347bb8a1056bfb1799691c11394257.1251465671.git.quintela@redhat.com> In-Reply-To: References: In-Reply-To: References: X-Scanned-By: MIMEDefang 2.67 on 10.5.11.16 X-detected-operating-system: by monty-python.gnu.org: Genre and OS details not recognized. Subject: [Qemu-devel] [PATCH 14/16] VMState: Fix sub-structs versioning X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org We can't check the version in a substruct, it is not stored anywhere Signed-off-by: Juan Quintela --- savevm.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/savevm.c b/savevm.c index 2b4054a..99fad79 100644 --- a/savevm.c +++ b/savevm.c @@ -1048,7 +1048,7 @@ int vmstate_load_state(QEMUFile *f, const VMStateDescription *vmsd, void *addr = base_addr + field->size * i; if (field->flags & VMS_STRUCT) { - ret = vmstate_load_state(f, field->vmsd, addr, version_id); + ret = vmstate_load_state(f, field->vmsd, addr, field->vmsd->version_id); } else { ret = field->info->get(f, addr, field->size);