[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    Re: Suspicous code in kdelibs-3.5.2
From:       "Aaron J. Seigo" <aseigo () kde ! org>
Date:       2006-04-05 17:57:25
Message-ID: 200604051157.25700.aseigo () kde ! org
[Download RAW message or body]


On Wednesday 05 April 2006 11:44, R.F. Pels wrote:
> On Wednesday 5 April 2006 19.08, Aaron J. Seigo wrote:
> >> i+n easily reaches the array bound 16. For example if n == 15 and i ==
> >> 14, then bm[29][0] is accessed. This is way behind the array bound.
> >
> > false positive. it's a 16x16 array and the code is taking advantage of
> > the fact that it's contiguous memory... so bm[29] is actually the 15th
> > element in the second "row"... fun.
>
> The C++ standard does not say anything about arrays of arrays being in
> contiguous memory, so this is not a false positive.

what platforms/compilers do we support where this isn't the case?

-- 
Aaron J. Seigo
GPG Fingerprint: 8B8B 2209 0C6F 7C47 B1EA  EE75 D6B7 2EB1 A7F1 DB43

Full time KDE developer sponsored by Trolltech (http://www.trolltech.com)

[Attachment #3 (application/pgp-signature)]

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic