mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-22 16:33:29 +00:00
(objectForAddress:): Return nil if address is not maintained by a
MallocAddress object. (Used to simply die.) git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@341 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
70e8c200ac
commit
40f9a58db7
1 changed files with 5 additions and 1 deletions
|
@ -39,7 +39,11 @@ static Dictionary* mallocAddresses;
|
|||
|
||||
+ objectForAddress: (void*)addr
|
||||
{
|
||||
return [mallocAddresses elementAtKey:addr].id_u;
|
||||
elt ret_nil(arglist_t a)
|
||||
{
|
||||
return (elt) nil;
|
||||
}
|
||||
return [mallocAddresses elementAtKey:addr ifAbsentCall:ret_nil].id_u;
|
||||
}
|
||||
|
||||
+ autoreleaseMallocAddresss: (void*)addr
|
||||
|
|
Loading…
Reference in a new issue