On (Wed) Nov 18 2009 [10:42:59], Kevin Wolf wrote:
> Signed-off-by: Kevin Wolf <kw...@redhat.com>
> ---
>  qemu-io.c |   10 ++++++----
>  1 files changed, 6 insertions(+), 4 deletions(-)
> 
> diff --git a/qemu-io.c b/qemu-io.c
> index cac72e9..c84b361 100644
> --- a/qemu-io.c
> +++ b/qemu-io.c
> @@ -129,7 +129,8 @@ create_iovec(QEMUIOVector *qiov, char **argv, int nr_iov, 
> int pattern)
>  {
>       size_t *sizes = calloc(nr_iov, sizeof(size_t));
>       size_t count = 0;
> -     void *buf, *p;
> +     void *buf = NULL;
> +     void *p;
>       int i;

I'd prefer the init to happen after the declarations -- brings in
consistent style, puts declarations in one blob and makes
initialisations explicit.


                Amit


Reply via email to