On Wednesday, February 27, 2002, at 08:46 AM, Manuel Guesdon wrote:

> Hi,
>
> There's a bug in KVC.
> When constructing setValue:forKey: method name, the method in has 
> garbage at the end (after the ':').
> In NSKeyValueCoding.m, I think there should be a
>       buf[size+5] = '\0';
> after each
>          buf[size+4] = ':';

Thanks ... fixed for the initial setup in takeValue:forKey and 
takeStoredValue:forKey:
I don't think there is anywhere else that needs it is there?

> BTW, is it possible to use strncpy instead of strcpy each time it's 
> possible to try to minimize buffer overflows, even if
> size seems to be well known ?

Well, if size isn't well known the code will fail anyway, so there 
doesn't seem much point.


PS. Also implemented MacOS-X compatible KVC behavior in NSDictionary.m


_______________________________________________
Bug-gnustep mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/bug-gnustep

Reply via email to