mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-31 16:50:58 +00:00
macosx compatibility fix.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@23269 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
325987015c
commit
0ef215b284
2 changed files with 5 additions and 1 deletions
|
@ -3,6 +3,8 @@
|
||||||
* Source/GSFormat.m: optimise a bit and fix bug where utf8 (and other
|
* Source/GSFormat.m: optimise a bit and fix bug where utf8 (and other
|
||||||
multibyte encodings) strings could be truncated at the wrong
|
multibyte encodings) strings could be truncated at the wrong
|
||||||
precision.
|
precision.
|
||||||
|
* Source/NSIndexPath.m: ([indexAtPosition:]) return NSNotFound if
|
||||||
|
given a bad position.
|
||||||
* Source/NSObject.m: implement CRASH_ON_ZOMBIE
|
* Source/NSObject.m: implement CRASH_ON_ZOMBIE
|
||||||
* Documentation/Base.gsdoc: document it.
|
* Documentation/Base.gsdoc: document it.
|
||||||
|
|
||||||
|
|
|
@ -196,7 +196,9 @@ static NSIndexPath *dummy = nil;
|
||||||
- (unsigned) indexAtPosition: (unsigned)position
|
- (unsigned) indexAtPosition: (unsigned)position
|
||||||
{
|
{
|
||||||
if (position >= _length)
|
if (position >= _length)
|
||||||
[NSException raise: NSRangeException format: @"Invalid location."];
|
{
|
||||||
|
return NSNotFound;
|
||||||
|
}
|
||||||
return _indexes[position];
|
return _indexes[position];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue