From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:57232) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fW0Z2-0003pr-2B for qemu-devel@nongnu.org; Thu, 21 Jun 2018 10:27:57 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fW0Z1-0007yr-7L for qemu-devel@nongnu.org; Thu, 21 Jun 2018 10:27:56 -0400 References: <20180621124937.166549-1-eblake@redhat.com> From: Eric Blake Message-ID: Date: Thu, 21 Jun 2018 09:27:50 -0500 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] nbd/server: Reject 0-length block status request List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Vladimir Sementsov-Ogievskiy , qemu-devel@nongnu.org Cc: jsnow@redhat.com, qemu-block@nongnu.org, qemu-stable@nongnu.org, Paolo Bonzini On 06/21/2018 07:52 AM, Vladimir Sementsov-Ogievskiy wrote: > 21.06.2018 15:49, Eric Blake wrote: >> The NBD spec says that behavior is unspecified if the client >> requests 0 length for block status; but since the structured >> reply is documenting as returning a non-zero length, it's >> easier to just diagnose this with an EINVAL error than to >> figure out what to return. >> >> CC: qemu-stable@nongnu.org >> Signed-off-by: Eric Blake > > Reviewed-by: Vladimir Sementsov-Ogievskiy Thanks; added to my NBD queue. Doing this makes it easier to add the assertion necessary to shut up gcc warning about an uninitialized variable in the other patches ready to pull. -- Eric Blake, Principal Software Engineer Red Hat, Inc. +1-919-301-3266 Virtualization: qemu.org | libvirt.org