From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=43516 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Ovxft-0004EX-Ne for qemu-devel@nongnu.org; Wed, 15 Sep 2010 15:29:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1Ovxfo-0005Gv-Rs for qemu-devel@nongnu.org; Wed, 15 Sep 2010 15:29:45 -0400 Received: from mx1.redhat.com ([209.132.183.28]:39191) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Ovxfo-0005Gq-K7 for qemu-devel@nongnu.org; Wed, 15 Sep 2010 15:29:40 -0400 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o8FJTdp2014337 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Wed, 15 Sep 2010 15:29:39 -0400 Message-ID: <4C911E9A.2020502@redhat.com> Date: Wed, 15 Sep 2010 21:29:30 +0200 From: Jes Sorensen MIME-Version: 1.0 References: <1284553440-17985-1-git-send-email-Jes.Sorensen@redhat.com> <1284553440-17985-3-git-send-email-Jes.Sorensen@redhat.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: [Qemu-devel] Re: [PATCH 2/5] Support human unit formats in strtobytes, eg. 1.0G List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Juan Quintela Cc: qemu-devel@nongnu.org, armbru@redhat.com On 09/15/10 16:50, Juan Quintela wrote: > Jes.Sorensen@redhat.com wrote: >> From: Jes Sorensen >> value <<= 10; >> break; >> case 0: >> + if (divider) { >> + value = 0; >> + break; > > changing break by goto fail here? > 1.5G and 1.0G is ok, but using 1024.00 or similar should be one error, > no? > > nice cleanup for the rest of the patch series. In my testing, 1234.5 fails as expected, so I expect 1024.00 to fail as well. Cheers, Jes