View Single Post
Old 05-31-2012, 02:22 AM   #17
Justin
Administrator
 
Justin's Avatar
 
Join Date: Jan 2005
Location: NYC
Posts: 15,721
Default

Actually (duh!), those jump instructions can be the 26 bit relative versions -- the addresses passed are relative anyway (but they are in bytes rather than dwords, which may need some tweaking). GLUE_MAX_JMPSIZE should be defined to the ~16 million max... I will update the calling code to use a GLUE_JMP_SET_OFFSET(instruction_end_buffer,offset) rather than having it directly replace the address using the GLUE_JMP_TYPE / GLUE_JMP_OFFSET / GLUE_JMP_OFFSET_MASK values (since the latter requires the address to fit in its own int or short).
Justin is offline   Reply With Quote