lclint-interest  

Re: buffer sizes and null pointers

Ken Raeburn
Sun, 26 May 2002 07:12:14 -0700

I wrote:
> I don't see a way to indicate that a maxSet relationship need only
> hold if the size is nonzero.  Perhaps maxSet(NULL) == 0 should be
> assumed?

Nope, silly me, I keep thinking "how many" when I should be thinking
"max index", so 0 is no good, it means one location can be set.
Perhaps -1?  Changing the literal value constructed in my patch still
produces a version that accepts my test case.

Ken