lkml.org 
[lkml]   [2008]   [Nov]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: 2.6.28-rc3: usb_hcd_poll_rh_status: array subscript is above array bounds
On Tue, 4 Nov 2008, Andrey Borzenkov wrote:

> > I think this is actually a compiler bug. It certainly has nothing to
> > do with USB. There was a discussion about it a month or so ago on
> > LKML.
> >
>
>
>
> Yes this really looks like a compiler bug, "length" hardly can be considered
> constant expression even using very broad definition of "constant".
>
> What is interesting though, it appears that compiler believes length has
> value of 5. So it will copy one extra byte; and possibly pass incorrect
> length to the caller. I cannot judge whether this garbage can do any harm.

Did you examine the object code? That's the only way to be sure.

> Dp you know if it was ever reported to gcc folks?

I have no idea. All I know is what was reported on LKML.

Alan Stern



\
 
 \ /
  Last update: 2008-11-04 17:13    [W:0.036 / U:0.100 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site