alastair@axis.UUCP (Alastair Adamson) (03/20/86)
I'm having lots of trouble trying to handle DOS fatal errors. I've written a routine in assembler and initialised the interrupt vector with its address (interrupt 24H). The routine gets called ok but either the program screws up a bit later or completely hangs. In the routine, I just restore all the user registers from the stack and do an "iret" with just the ip, cs and flags (from when I called bios) left on the stack. I also try saving the error id (from di) in a program global variable (after having restored ds) and this seems to get set ok. Alternatively, I have also tried just saving di in a variable carefully placed in the code segment, setting al to 0 and doing an iret to let dos handle the stack. The results are equally disasterous. I would greatly appreciate any hints, help or other wisdom on the subject. Thanks in advance (and I will also personally thank any responders afterwards!).