On Tuesday, 15 May 2012 at 21:58:56 UTC, Alex Rønne Petersen wrote:
On 15-05-2012 23:27, deadalnix wrote:
Le 15/05/2012 21:33, Mehrdad a écrit :
How do get the address of a function in naked assembly code?

void foo()
{
asm
{
naked;
mov EAX, &foo;
}
}

This doesn't work...

As it is naked,

mov EAX, EIP;

is enough.

I suspect he wanted a solution where he could load an arbitrary function's address.

indeed

Reply via email to