mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-23 00:41:02 +00:00
Fix another small memory allocation issue.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@32537 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
82d7dabe9e
commit
622ad2647f
1 changed files with 14 additions and 7 deletions
|
@ -436,13 +436,20 @@ static NSUInteger _defaultBehavior = NSNumberFormatterBehavior10_4;
|
|||
#if GS_USE_ICU == 1
|
||||
unum_close (internal->_formatter);
|
||||
#endif
|
||||
for (idx = 0 ; idx < MAX_SYMBOLS ; ++idx )
|
||||
RELEASE(internal->_symbols[idx]);
|
||||
NSZoneFree (z, internal->_symbols);
|
||||
for (idx = 0 ; idx < MAX_TEXTATTRIBUTES ; ++idx )
|
||||
RELEASE(internal->_textAttributes[idx]);
|
||||
NSZoneFree (z, internal->_textAttributes);
|
||||
NSZoneFree (z, internal->_attributes);
|
||||
if (internal->_symbols)
|
||||
{
|
||||
for (idx = 0 ; idx < MAX_SYMBOLS ; ++idx )
|
||||
RELEASE(internal->_symbols[idx]);
|
||||
NSZoneFree (z, internal->_symbols);
|
||||
}
|
||||
if (internal->_textAttributes)
|
||||
{
|
||||
for (idx = 0 ; idx < MAX_TEXTATTRIBUTES ; ++idx )
|
||||
RELEASE(internal->_textAttributes[idx]);
|
||||
NSZoneFree (z, internal->_textAttributes);
|
||||
}
|
||||
if (internal->_attributes)
|
||||
NSZoneFree (z, internal->_attributes);
|
||||
GS_DESTROY_INTERNAL(NSNumberFormatter)
|
||||
}
|
||||
[super dealloc];
|
||||
|
|
Loading…
Reference in a new issue