On Wed, Dec 21, 2011 at 09:43:55AM -0700, Eric Blake wrote:
> On 12/21/2011 09:00 AM, Stefan Hajnoczi wrote:
> > The qemu-img.c:is_not_zero() function checks if a buffer contains all
> > zeroes. This function will come in handy for zero-detection in the
> > block layer, so clean it up and move it
On 12/21/2011 09:00 AM, Stefan Hajnoczi wrote:
> The qemu-img.c:is_not_zero() function checks if a buffer contains all
> zeroes. This function will come in handy for zero-detection in the
> block layer, so clean it up and move it to cutils.c.
>
> Note that the function now returns true if the buf
The qemu-img.c:is_not_zero() function checks if a buffer contains all
zeroes. This function will come in handy for zero-detection in the
block layer, so clean it up and move it to cutils.c.
Note that the function now returns true if the buffer is all zeroes.
This avoids the double-negatives (i.e.