Mail Archives: djgpp/1996/07/24/11:45:27
On Wed, 24 Jul 1996 Sengan DOT Short AT durham DOT ac DOT uk wrote:
> Is that all we have to do? Allocate dos memory, and switch the above
> value ?
That is the source of non-reentrancy in ALL functions that invoke
real-mode (DOS and BIOS) services, yes. After fixing this, one should
scan libc and look for other causes of non-reentrancy. I make a rule to
never call any library function from a multithreaded program if I don't
know *exactly* what that function does.
> What about malloc: it has a nextf[] structure it uses, so probably is not
> reentrant, right? Do you know of any other functions that might be non-reentrant
> like this?
AFAIK, nobody has made libc functions clean wrt to the reentrancy. So
most probably there are other functions that will fail.
- Raw text -