From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=56946 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PPd3S-0001GY-0f for qemu-devel@nongnu.org; Mon, 06 Dec 2010 10:32:44 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PPd3Q-0008H9-FE for qemu-devel@nongnu.org; Mon, 06 Dec 2010 10:32:41 -0500 Received: from mx1.redhat.com ([209.132.183.28]:1030) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PPd3Q-0008H2-83 for qemu-devel@nongnu.org; Mon, 06 Dec 2010 10:32:40 -0500 Message-ID: <4CFD0258.8070608@redhat.com> Date: Mon, 06 Dec 2010 16:33:44 +0100 From: Kevin Wolf MIME-Version: 1.0 References: <1291645540-9784-1-git-send-email-Jes.Sorensen@redhat.com> In-Reply-To: <1291645540-9784-1-git-send-email-Jes.Sorensen@redhat.com> Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 7bit Subject: [Qemu-devel] Re: [PATCH v3 0/7] Cleanup qemu-img code List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Jes.Sorensen@redhat.com Cc: stefanha@linux.vnet.ibm.com, qemu-devel@nongnu.org Am 06.12.2010 15:25, schrieb Jes.Sorensen@redhat.com: > From: Jes Sorensen > > Hi, > > These patches applies a number of cleanups to qemu-img.c as well as a > minor bug in qemu-malloc.c. > > The handling of block help printing is moved to shared code, which > allows the "?" detection to happen early in the parsing, instead of > half way down img_create() and img_convert(). I would like to see this > happen as I would like to pull some of the code out of img_create() > and into block.c so it can be shared with qemu and qemu-img. > > In addition there is a couple of patches to clean up the error > handling in qemu-img.c and make it more consistent. > > The formatting patch is solely because the last patch wanted to > change code next to the badly formatted code, and I didn't want to > pollute the patch with the formatting fixed. > > The seventh patch fixes qemu-img to exit on detection of unknown > options instead of continuing with a potentially wrong set of > arguments. > > v3 applies a number of changes discussed on irc and email. This is the > grow to seven from three patches series. > > Cheers, > Jes > > Jes Sorensen (7): > Add missing tracing to qemu_mallocz() > Use qemu_mallocz() instead of calloc() in img_convert() > img_convert(): Only try to free bs[] entries if bs is valid. > Make error handling more consistent in img_create() and img_resize() > Consolidate printing of block driver options > Fix formatting and missing braces in qemu-img.c > Fail if detecting an unknown option > > qemu-img.c | 162 +++++++++++++++++++++++++++++++++++++++----------------- > qemu-malloc.c | 5 ++- > 2 files changed, 117 insertions(+), 50 deletions(-) Thanks, applied all except patch 4, which breaks the build. Please resend a new version of patch 4 as a single patch without the rest of the series. Kevin