From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LcjHw-0002J5-BH for qemu-devel@nongnu.org; Thu, 26 Feb 2009 11:40:44 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LcjHu-0002IF-NM for qemu-devel@nongnu.org; Thu, 26 Feb 2009 11:40:43 -0500 Received: from [199.232.76.173] (port=34409 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LcjHu-0002I5-H2 for qemu-devel@nongnu.org; Thu, 26 Feb 2009 11:40:42 -0500 Received: from e2.ny.us.ibm.com ([32.97.182.142]:58622) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1LcjHt-0006z6-Ke for qemu-devel@nongnu.org; Thu, 26 Feb 2009 11:40:41 -0500 Received: from d01relay04.pok.ibm.com (d01relay04.pok.ibm.com [9.56.227.236]) by e2.ny.us.ibm.com (8.13.1/8.13.1) with ESMTP id n1QGcM8S004719 for ; Thu, 26 Feb 2009 11:38:22 -0500 Received: from d01av03.pok.ibm.com (d01av03.pok.ibm.com [9.56.224.217]) by d01relay04.pok.ibm.com (8.13.8/8.13.8/NCO v9.2) with ESMTP id n1QGeeJd142962 for ; Thu, 26 Feb 2009 11:40:40 -0500 Received: from d01av03.pok.ibm.com (loopback [127.0.0.1]) by d01av03.pok.ibm.com (8.12.11.20060308/8.13.3) with ESMTP id n1QGeehi025440 for ; Thu, 26 Feb 2009 11:40:40 -0500 Received: from squirrel.codemonkey.ws (dyn9053041157.austin.ibm.com [9.53.41.157]) by d01av03.pok.ibm.com (8.12.11.20060308/8.12.11) with ESMTP id n1QGeeJL025403 for ; Thu, 26 Feb 2009 11:40:40 -0500 Message-ID: <49A6C607.9090002@us.ibm.com> Date: Thu, 26 Feb 2009 10:40:39 -0600 From: Anthony Liguori MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH] fix raw_aio_remove References: <499C3D4D.9060108@eu.citrix.com> In-Reply-To: <499C3D4D.9060108@eu.citrix.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Stefano Stabellini wrote: > Hi all, > this small patch fixes a bug in the list iteration of raw_aio_remove. > Cheers, > Applied. Thanks. Regards, Anthony Liguori > Stefano > > Signed-off-by: Stefano Stabellini > > > diff --git a/block-raw-posix.c b/block-raw-posix.c > index 620791b..85ca704 100644 > --- a/block-raw-posix.c > +++ b/block-raw-posix.c > @@ -604,13 +604,14 @@ static void raw_aio_remove(RawAIOCB *acb) > pacb = &posix_aio_state->first_aio; > for(;;) { > if (*pacb == NULL) { > + fprintf(stderr, "raw_aio_remove: aio request not found!\n"); > break; > } else if (*pacb == acb) { > *pacb = acb->next; > qemu_aio_release(acb); > break; > } > - pacb = &acb->next; > + pacb = &(*pacb)->next; > } > } > > > > >