nummish wrote:
> .. I wonder if it's because this is a stret call, or if it's just a
> bad example. I'll take a look for a better example later tonight.
>
yes, _objc_msgSend_stret is an assembler function from the objective-C
runtime
source code can be found here: http://www.opensource.apple.com/darwinsource/
look for 'objc4-XXX.tar.gz
that is a bit strange function, you can't really declare something like
that in C.
looking at the assembler source, it ends with 'retn 4', and takes a
variable nr of arguments.
and ida incorrectly assumes it is a C style '__stdcall' type function
with 3 parameters
if you type ALT-K on a line with 'call _objc_msgSend_stret'
it says '0xC'
you can fix this by going to the _objc_msgSend_stret function, and changing
'purged bytes' in alt-P from 0xC to 0x4
then the stack will look fine everywhere.
_objc_msgForward has the same issue.
willem
|