mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-20 12:16:40 +00:00
fix leak
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@31778 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
ad58931bde
commit
2671ff98e5
2 changed files with 14 additions and 6 deletions
|
@ -1804,9 +1804,12 @@ handle_printf_atsign (FILE *stream,
|
|||
- (NSString*) stringByReplacingCharactersInRange: (NSRange)aRange
|
||||
withString: (NSString*)by
|
||||
{
|
||||
id copy = [self mutableCopy];
|
||||
id copy;
|
||||
|
||||
copy = [[GSMutableStringClass allocWithZone: NSDefaultMallocZone()]
|
||||
initWithString: self];
|
||||
[copy replaceCharactersInRange: aRange withString: by];
|
||||
return [copy makeImmutableCopyOnFail: NO];
|
||||
return [[copy makeImmutableCopyOnFail: NO] autorelease];
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue