Talk About Network



Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > MSDOS Programmer > Re: Trap Int21h...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 2 of 2 Topic 438 of 494
Post > Topic >>

Re: Trap Int21h problem

by "gerotica" <pgerotica@[EMAIL PROTECTED] > Mar 24, 2007 at 12:35 AM

I dont see a superficial problem calling int21 to change int21 vector,
because when it reaches its internal functions to actually write the
vector, the jump is done a long time ago.... well, that=B4s my
opnion...
Anyway, i tried to change the code to use direct write of the vector:

int  seg, off;

seg =3D FP_SEG(int21);
off =3D FP_OFF(int21);

asm{
  push ax;
  push es;
  mov ax, 0;
  mov es, ax;
  mov ax, off;
  mov word ptr es:0x86, ax;
  mov ax, seg;
  mov word ptr es:0x84, ax;
  pop es;
  pop ax;
}

Also, I=B4ve tested indos and critical error flag before change the
vector, tried to remove the "interrupt" directive from int21
declaration, and changed to _chain_intr(old21). All of them gives me
the same error...   looks like when the program is exiting,
command.com freezes, it never gets to the prompt again.




 2 Posts in Topic:
Trap Int21h problem
"gerotica" <  2007-03-23 20:56:19 
Re: Trap Int21h problem
"gerotica" <  2007-03-24 00:35:04 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sat May 17 7:41:37 CDT 2008.