Compare with a range of length zero should always return NSOrderedSame

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@3503 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Richard Frith-MacDonald 1998-12-26 08:44:49 +00:00
parent 52f6bc90ae
commit 2f07b4d007

View file

@ -1346,6 +1346,8 @@ handle_printf_atsign (FILE *stream,
if (aRange.length > ([self length] - aRange.location))
[NSException raise: NSRangeException format:@"Invalid location+length."];
if (aRange.length == 0)
return NSOrderedSame;
if((([self length] - aRange.location == 0) && (![aString length])))
return NSOrderedSame;
if(![self length])