From patchwork Sat Jan 3 08:45:08 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paolo Bonzini X-Patchwork-Id: 425099 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 57308140081 for ; Sat, 3 Jan 2015 19:51:21 +1100 (AEDT) Received: from localhost ([::1]:53809 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Y7KQZ-0002nQ-Ki for incoming@patchwork.ozlabs.org; Sat, 03 Jan 2015 03:51:19 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:44912) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Y7KL3-00023p-9l for qemu-devel@nongnu.org; Sat, 03 Jan 2015 03:45:38 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Y7KKx-0002ni-Kv for qemu-devel@nongnu.org; Sat, 03 Jan 2015 03:45:37 -0500 Received: from mail-wi0-x234.google.com ([2a00:1450:400c:c05::234]:48502) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Y7KKw-0002mC-Rm for qemu-devel@nongnu.org; Sat, 03 Jan 2015 03:45:31 -0500 Received: by mail-wi0-f180.google.com with SMTP id n3so598082wiv.7 for ; Sat, 03 Jan 2015 00:45:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=gjkKOE/63EykETU8LZdLXvD+teqBRnl5zkK8OG8WPGU=; b=r8/P7sVR1qebS28cyS++oa3kCD7pxan3BA2hbn+yKi85KoReoRWdaxColL+nf1FIue j0m+D5DZLYbb83IR3hPPhwWNuGPpOFizKDD7CP+krOyXjhLJe65LQWGwRSKQ+pbJJo2B 6oZRKumYmtF7nzw9zldBy0CfFuHMiLKdrQp5E4clGIbm9OyMEibguspgNjtqjRWCcHLb 0fKMx16Nl2ItMGbf6xIRs5RDzt6y35n6FDfcsCkSx1mCRYWLolv3Oisb/BGXmxvnd2Pe 0lW9FOTxAQXuYlNyX2q+DkfejRGHBc1P70qO+FvjREBwV+FOvX77sXhgyBnSz+dZfrnx 4jbA== X-Received: by 10.180.78.202 with SMTP id d10mr5179460wix.82.1420274730249; Sat, 03 Jan 2015 00:45:30 -0800 (PST) Received: from playground.station (net-37-117-147-67.cust.vodafonedsl.it. [37.117.147.67]) by mx.google.com with ESMTPSA id i3sm1810418wie.23.2015.01.03.00.45.28 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 03 Jan 2015 00:45:29 -0800 (PST) From: Paolo Bonzini To: qemu-devel@nongnu.org Date: Sat, 3 Jan 2015 09:45:08 +0100 Message-Id: <1420274709-30199-9-git-send-email-pbonzini@redhat.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1420274709-30199-1-git-send-email-pbonzini@redhat.com> References: <1420274709-30199-1-git-send-email-pbonzini@redhat.com> X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:400c:c05::234 Cc: Peter Wu Subject: [Qemu-devel] [PULL 8/9] block/iscsi: fix uninitialized variable X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org From: Peter Wu 'ret' was never initialized in the success path. Signed-off-by: Peter Wu Signed-off-by: Paolo Bonzini --- block/iscsi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/block/iscsi.c b/block/iscsi.c index ed375fc..12ddbfb 100644 --- a/block/iscsi.c +++ b/block/iscsi.c @@ -1286,7 +1286,7 @@ static int iscsi_open(BlockDriverState *bs, QDict *options, int flags, QemuOpts *opts; Error *local_err = NULL; const char *filename; - int i, ret; + int i, ret = 0; if ((BDRV_SECTOR_SIZE % 512) != 0) { error_setg(errp, "iSCSI: Invalid BDRV_SECTOR_SIZE. "