hello
i want to jump to a specific place in the code
which i know it's place just in RUN-TIME
could anyone help me please?

i tried:
mov bx, new_ip
jmp

but it doesn't do anything

thanks in advance
Posted on 2002-02-08 01:39:05 by arkon
Imho you don't need [] if it represents directly the offset you want to jump to.
Posted on 2002-02-08 01:49:32 by JCP
There's quite a few ways to go about it :). Two of the most useful
are probably the following:



mov [i]reg[/i], [b]addr[/b]
jmp [i]reg[/i]

(7 bytes)

and



push [b]addr[/b]
ret

(6 bytes)
Posted on 2002-02-08 13:09:56 by f0dder
hehe my prob was that i jumped to offset 0 in a .com file
which have a program-termination code in that place in the psp
that should be 0x100 :)

hmm
push new_ip
ret is very cool idea
i have never seen it before

how would you get the current ip in run time?
(call $+3
pop cur_ip)

do you know other cool tricks??
Posted on 2002-02-08 14:07:10 by arkon