mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-29 16:01:38 +00:00
Invocation fixes
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@15873 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
22206c66f3
commit
b30484a6c0
5 changed files with 66 additions and 5 deletions
|
@ -278,13 +278,17 @@ GSFFIInvokeWithTargetAndImp(NSInvocation *_inv, id anObject, IMP imp)
|
|||
id old_target;
|
||||
IMP imp;
|
||||
|
||||
CLEAR_RETURN_VALUE_IF_OBJECT;
|
||||
_validReturn = NO;
|
||||
|
||||
/*
|
||||
* A message to a nil object returns nil.
|
||||
*/
|
||||
if (anObject == nil)
|
||||
{
|
||||
if (_retval)
|
||||
memset(_retval, '\0', _info[0].size); /* Clear return value */
|
||||
memset(_retval, '\0', _info[0].size); /* Clear return value */
|
||||
_validReturn = YES;
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -335,6 +339,8 @@ GSFFIInvokeWithTargetAndImp(NSInvocation *_inv, id anObject, IMP imp)
|
|||
/* Decode the return value */
|
||||
if (*_info[0].type != _C_VOID)
|
||||
cifframe_decode_arg(_info[0].type, _retval);
|
||||
|
||||
RETAIN_RETURN_VALUE;
|
||||
_validReturn = YES;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue