Havoc Pennington wrote:

> "Peter  Garner" <[EMAIL PROTECTED]> writes:
> >
> > Really?  Thanks for the heads up!!!
>
> The return value has to be stored in memory somewhere; if the compiler
> thinks there is no return value when invoking the function pointer it
> doesn't have to make that memory. But if the function being invoked
> has a return value it will put the return value there anyway.

Actually, it's very common for integal return values to be left in a register,
not in memory. So returning a value would not cause memory corruption. For
example, on x86, gcc leaves the return value in the EAX register.

--
Paul Carter [[EMAIL PROTECTED]] [http://www.comsc.ucok.edu/~pcarter]



-- 
To unsubscribe: mail -s unsubscribe [EMAIL PROTECTED] < /dev/null

Reply via email to