qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] Re: [PATCH] scsi: Implement alloc_req_iov callback


From: Stefan Hajnoczi
Subject: [Qemu-devel] Re: [PATCH] scsi: Implement alloc_req_iov callback
Date: Mon, 22 Nov 2010 21:48:42 +0000

On Mon, Nov 22, 2010 at 10:15 AM, Hannes Reinecke <address@hidden> wrote:
Looks good.  If you send out another version of the patchset you might
like to fix this nitpick:

> +    if (!r->io_header.iovec_count) {
> +        if (r->buflen != r->req.cmd.xfer) {
> +            if (r->buf != NULL)
> +                qemu_free(r->buf);

qemu_free(NULL) is a nop so it's safe to drop the if (r->buf != NULL)
check and just use qemu_free(r->buf) unconditionally.  That's nice
since it also fixes the if statement without curly braces.

Stefan



reply via email to

[Prev in Thread] Current Thread [Next in Thread]