delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/1996/03/13/10:55:59

Date: Wed, 13 Mar 1996 17:48:26 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: Douglas Rupp <drupp AT cs DOT washington DOT edu>
Cc: Charles Sandmann <sandmann AT clio DOT rice DOT edu>, djgpp-v2 AT delorie DOT com
Subject: Re: Itimer/Signal handler bug?
In-Reply-To: <199603111850.KAA24774@june.cs.washington.edu>
Message-Id: <Pine.SUN.3.91.960313174212.10443D-100000@is>
Mime-Version: 1.0

On Mon, 11 Mar 1996, Douglas Rupp wrote:

> There is, reportedly, an undocumented DOS call that will save and restore
> state there, I have it in another threads package but haven;t tested it.

If you are talking about the Swappable Data Area (SDA), then beware: it 
would probably work under native DOS, but I'd expect it to crash and burn 
under Win 3.11 and Win95 when 32-bit file access is used (to say nothing 
about WinNT and Linux).  All these work by catching DOS calls and 
redirecting them into totally different code and data structures.  Now 
guess: what are the chances that MS designed those replacements for DOS 
to be reentrant?

The code to get the address of the SDA can be found on stat.c in the DJGPP
library sources.  There is no DOS call to swap it in or out AFAIK;  you
will have to do it yourself.  There are more details about this technique
in the chapter on TSRs in ``Undocumented DOS'', 2nd ed. 

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019