qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [Qemu-trivial] [PATCH] cadence_gem: Avoid stack-writing


From: Stefan Hajnoczi
Subject: Re: [Qemu-devel] [Qemu-trivial] [PATCH] cadence_gem: Avoid stack-writing buffer-overrun
Date: Fri, 22 Jun 2012 10:03:31 +0100
User-agent: Mutt/1.5.21 (2010-09-15)

On Tue, Jun 19, 2012 at 04:44:38PM +1000, Peter A. G. Crosthwaite wrote:
> From: Jim Meyering <address@hidden>
> 
> Use sizeof(rxbuf)-size (not sizeof(rxbuf-size)) as the number
> of bytes to clear.  The latter would always clear 4 or 8
> bytes, possibly writing beyond the end of that stack buffer.
> Alternatively, depending on the value of the "size" parameter,
> it could fail to initialize the end of "rxbuf".
> Spotted by coverity.
> 
> Signed-off-by: Jim Meyering <address@hidden>
> Signed-off-by: Peter A. G. Crosthwaite <address@hidden>
> ---
>  hw/cadence_gem.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)

Thanks, applied to the trivial patches tree:
https://github.com/stefanha/qemu/commits/trivial-patches

Stefan



reply via email to

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