From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:33057) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SZ0iN-0000L6-3N for qemu-devel@nongnu.org; Mon, 28 May 2012 10:14:35 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SZ0iI-0005Qr-6k for qemu-devel@nongnu.org; Mon, 28 May 2012 10:14:30 -0400 Received: from cantor2.suse.de ([195.135.220.15]:52200 helo=mx2.suse.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SZ0iH-0005Qj-WC for qemu-devel@nongnu.org; Mon, 28 May 2012 10:14:26 -0400 Message-ID: <4FC38836.4030102@suse.de> Date: Mon, 28 May 2012 16:14:14 +0200 From: =?ISO-8859-1?Q?Andreas_F=E4rber?= MIME-Version: 1.0 References: <1337721812-30229-1-git-send-email-sw@weilnetz.de> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH 1.1] virtio: Fix compiler warning for non Linux hosts List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Stefan Weil Cc: Kevin Wolf , Stefan Hajnoczi , Anthony Liguori , qemu-devel@nongnu.org, Paolo Bonzini Am 23.05.2012 10:09, schrieb Stefan Hajnoczi: > On Tue, May 22, 2012 at 10:23 PM, Stefan Weil wrote: >> The local variables ret, i are only used if __linux__ is defined. >> >> Signed-off-by: Stefan Weil >> --- >> hw/virtio-blk.c | 4 +++- >> 1 file changed, 3 insertions(+), 1 deletion(-) >=20 > The #ifdef __linux__ further down in the function declares the local > hdr variable. We could move ret and i down into the #ifdef instead of > adding a new one. Sorry, this patch seems to have passed me by: I posted a patch moving all Linux variables into an #ifdef at the top. http://patchwork.ozlabs.org/patch/161546/ Andreas --=20 SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N=FCrnberg, Germany GF: Jeff Hawn, Jennifer Guild, Felix Imend=F6rffer; HRB 16746 AG N=FCrnbe= rg