From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NVAES-000677-6s for qemu-devel@nongnu.org; Wed, 13 Jan 2010 15:54:24 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NVAEN-00063Z-Ky for qemu-devel@nongnu.org; Wed, 13 Jan 2010 15:54:23 -0500 Received: from [199.232.76.173] (port=33070 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NVAEL-00063M-Uq for qemu-devel@nongnu.org; Wed, 13 Jan 2010 15:54:18 -0500 Received: from mx20.gnu.org ([199.232.41.8]:19415) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1NVAEL-0001cy-FE for qemu-devel@nongnu.org; Wed, 13 Jan 2010 15:54:17 -0500 Received: from mx1.redhat.com ([209.132.183.28]) by mx20.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NVAEJ-0008Nw-UU for qemu-devel@nongnu.org; Wed, 13 Jan 2010 15:54:16 -0500 Received: from int-mx05.intmail.prod.int.phx2.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.18]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o0DKsBwC028051 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Wed, 13 Jan 2010 15:54:12 -0500 Date: Wed, 13 Jan 2010 22:51:15 +0200 From: "Michael S. Tsirkin" Message-ID: <20100113205115.GC21445@redhat.com> References: <1263380087-31821-1-git-send-email-amit.shah@redhat.com> <1263380087-31821-2-git-send-email-amit.shah@redhat.com> <1263380087-31821-3-git-send-email-amit.shah@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1263380087-31821-3-git-send-email-amit.shah@redhat.com> Subject: [Qemu-devel] Re: [PATCH 2/6] virtio: net: remove dead assignment List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Amit Shah Cc: qemu-devel@nongnu.org On Wed, Jan 13, 2010 at 04:24:43PM +0530, Amit Shah wrote: > clang-analyzer points out value assigned to 'len' is not used. > > Signed-off-by: Amit Shah Acked-by: Michael S. Tsirkin > --- > hw/virtio-net.c | 2 +- > 1 files changed, 1 insertions(+), 1 deletions(-) > > diff --git a/hw/virtio-net.c b/hw/virtio-net.c > index 02d9180..6e48997 100644 > --- a/hw/virtio-net.c > +++ b/hw/virtio-net.c > @@ -532,7 +532,7 @@ static ssize_t virtio_net_receive(VLANClientState *nc, const uint8_t *buf, size_ > int len, total; > struct iovec sg[VIRTQUEUE_MAX_SIZE]; > > - len = total = 0; > + total = 0; > > if ((i != 0 && !n->mergeable_rx_bufs) || > virtqueue_pop(n->rx_vq, &elem) == 0) { > -- > 1.6.2.5 > >