From patchwork Tue Apr 20 21:09:32 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Luiz Capitulino X-Patchwork-Id: 50576 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 ozlabs.org (Postfix) with ESMTPS id EA19DB7CF5 for ; Wed, 21 Apr 2010 07:20:47 +1000 (EST) Received: from localhost ([127.0.0.1]:54696 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1O4KoB-000083-Cw for incoming@patchwork.ozlabs.org; Tue, 20 Apr 2010 17:16:39 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1O4Khw-00076O-1e for qemu-devel@nongnu.org; Tue, 20 Apr 2010 17:10:12 -0400 Received: from [140.186.70.92] (port=37217 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1O4Kho-00073N-AJ for qemu-devel@nongnu.org; Tue, 20 Apr 2010 17:10:11 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1O4Khm-0003u8-M5 for qemu-devel@nongnu.org; Tue, 20 Apr 2010 17:10:04 -0400 Received: from mx1.redhat.com ([209.132.183.28]:28688) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1O4Khm-0003ty-9b for qemu-devel@nongnu.org; Tue, 20 Apr 2010 17:10:02 -0400 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o3KLA1nD016763 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 20 Apr 2010 17:10:01 -0400 Received: from localhost (vpn-9-57.rdu.redhat.com [10.11.9.57]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o3KLA0l2021283; Tue, 20 Apr 2010 17:10:01 -0400 From: Luiz Capitulino To: qemu-devel@nongnu.org, armbru@redhat.com, quintela@redhat.com, kwolf@redhat.com Date: Tue, 20 Apr 2010 18:09:32 -0300 Message-Id: <1271797792-24571-3-git-send-email-lcapitulino@redhat.com> In-Reply-To: <1271797792-24571-1-git-send-email-lcapitulino@redhat.com> References: <1271797792-24571-1-git-send-email-lcapitulino@redhat.com> X-Scanned-By: MIMEDefang 2.67 on 10.5.11.12 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. Cc: Subject: [Qemu-devel] [PATCH 02/22] savevm: Don't check the return of qemu_fopen_bdrv() 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 It never fails. Signed-off-by: Luiz Capitulino --- savevm.c | 8 -------- 1 files changed, 0 insertions(+), 8 deletions(-) diff --git a/savevm.c b/savevm.c index 086c92a..254f9fc 100644 --- a/savevm.c +++ b/savevm.c @@ -1705,10 +1705,6 @@ void do_savevm(Monitor *mon, const QDict *qdict) /* save the VM state */ f = qemu_fopen_bdrv(bs, 1); - if (!f) { - monitor_printf(mon, "Could not open VM state file\n"); - goto the_end; - } ret = qemu_savevm_state(mon, f); vm_state_size = qemu_ftell(f); qemu_fclose(f); @@ -1790,10 +1786,6 @@ int load_vmstate(const char *name) /* restore the VM state */ f = qemu_fopen_bdrv(bs, 0); - if (!f) { - error_report("Could not open VM state file"); - return -EINVAL; - } ret = qemu_loadvm_state(f); qemu_fclose(f); if (ret < 0) {