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

From: sandmann AT clio DOT rice DOT edu (Charles Sandmann)
Message-Id: <9603130621.AA16804@clio.rice.edu>
Subject: sbrk() bug
To: djgpp-v2 AT delorie DOT com (DJGPP V2 developers)
Date: Wed, 13 Mar 1996 00:21:40 -0600 (CST)

Matthias Grimrath has been working on an alternate stub+dpmi provider 
combined into a single package.  It's built with TASM+TLINK, and the DPMI
is based on Tran's PMODE.  Its a neat package, still in shakedown development.

Anyway, he found a bug in sbrk() (sigh) using this new package.  With the
new multi-memory-zone sbrk(), if the DPMI provider does not provide page
aligned memory zones, and gets upset about the lower 12 bits being one
in limit sets, then the selector limit bump fails on DS and so you would
see a GPF.  I don't know how much of a problem this would be in the non-PMODE
world, since CWSDPMI and other providers do page align, or provide memory
zones back to back (which also guarantees alignment).  Maybe under a shared
memory, multi-tasking DPMI (which gets a block between yours) it might
mess up, I don't know for sure.  So, if anyone is seeing random GPFs under
a Win type environment when running other progs, this might be a cause.
There is a simple 1 line fix if anyone feels the need to try it.

- Raw text -


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