Colin Harrison wrote:
> Hi,
> 
> I needed this patch in the wrapper around vsnprintf() in os/xprintf.c (MinGW
> for Windows build) to correct various crashes.
> 
> --- ./os/save_xprintf.c 2010-12-09 00:01:19.000000000 +0000
> +++ ./os/xprintf.c      2010-12-09 23:47:34.000000000 +0000
> @@ -108,7 +108,7 @@
>          return -1;
> 
>      vsnprintf(*ret, size + 1, format, va);
> -    ret[size] = 0;
> +    (*ret)[size] = 0;
>      return size;
>  #endif
>  }

Ouch! Sorry about that.   (Though the whole line may not really be
necessary at all, since the vsnprintf should be null terminating it.)

Reviewed-by: Alan Coopersmith <[email protected]>

-- 
        -Alan Coopersmith-        [email protected]
         Oracle Solaris Platform Engineering: X Window System

_______________________________________________
[email protected]: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel

Reply via email to