From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:36459) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ystn8-0004ER-Lf for qemu-devel@nongnu.org; Thu, 14 May 2015 10:07:19 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Ystn4-0007T4-KF for qemu-devel@nongnu.org; Thu, 14 May 2015 10:07:14 -0400 Received: from mx1.redhat.com ([209.132.183.28]:43268) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ystn4-0007SZ-Eu for qemu-devel@nongnu.org; Thu, 14 May 2015 10:07:10 -0400 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (Postfix) with ESMTPS id 217828E6F1 for ; Thu, 14 May 2015 14:07:10 +0000 (UTC) Message-ID: <5554AC0C.3020805@redhat.com> Date: Thu, 14 May 2015 08:07:08 -0600 From: Eric Blake MIME-Version: 1.0 References: <1431599702-10431-1-git-send-email-pbonzini@redhat.com> In-Reply-To: <1431599702-10431-1-git-send-email-pbonzini@redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="E8FmR8pC3dpbQHVX8T9nG7R6JAKQJdHxD" Subject: Re: [Qemu-devel] [PATCH] block: get_block_status: use "else" when testing the opposite condition List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini , qemu-devel@nongnu.org Cc: famz@redhat.com, stefanha@redhat.com This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --E8FmR8pC3dpbQHVX8T9nG7R6JAKQJdHxD Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 05/14/2015 04:35 AM, Paolo Bonzini wrote: > A bit of Boolean algebra (and common sense) tells us that the > second "if" here is looking for blocks that are not allocated. > This is the opposite of the "if" that sets BDRV_BLOCK_ALLOCATED, > and thus it can use an "else". >=20 > Signed-off-by: Paolo Bonzini > --- > block/io.c | 4 +--- > 1 file changed, 1 insertion(+), 3 deletions(-) Reviewed-by: Eric Blake --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --E8FmR8pC3dpbQHVX8T9nG7R6JAKQJdHxD Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJVVKwMAAoJEKeha0olJ0Nq5Z4H/j0jITj9cH5ch/TxOv4wGLHA u9Ph/pbcgs1v+yBmwm+Z3l7qAgGVMWMMFFKhaxJPLi+vZBdmMSxymaDk63Dv8U3t qhOvpIgrJJooe84kjqjksJdtX7EQ6Bg317VyrbALl8+RSKi1DSI+ICEh4u9ZZ9jc KaaeR6K2aNVbz2lUMVvPMSrSkNHdhRKRkhAqcv2QnuJpGH+3bVJRFziXAzigmij8 799Sgz6kKQWCG288NUuK96QdSWaRCWRiHIfrEmxvpsk8AW1x359QgSlU4cTk1Ko8 Cy8Vfzv1fzOZWIW1eCbEVGTm1OqilY0re9tOmQJ/2bahwGHcLap8v3j+jex8yog= =Jb5v -----END PGP SIGNATURE----- --E8FmR8pC3dpbQHVX8T9nG7R6JAKQJdHxD--