www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2001/12/06/16:02:50

X-Authentication-Warning: delorie.com: mailnull set sender to djgpp-bounces using -f
From: "Charles Sandmann" <sandmann AT clio DOT rice DOT edu>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Running any of the OpenGUI examples in dos mode crashes...
Date: Thu, 6 Dec 2001 13:57:46
Organization: Aspen Technology, Inc.
Lines: 43
Message-ID: <3c0f795a.sandmann@clio.rice.edu>
References: <4e52c237 DOT 0112061151 DOT 5ed1c367 AT posting DOT google DOT com>
NNTP-Posting-Host: dcloan.hou.aspentech.com
X-Trace: selma.aspentech.com 1007671892 11592 10.32.115.107 (6 Dec 2001 20:51:32 GMT)
X-Complaints-To: postmaster AT aspentech DOT com
NNTP-Posting-Date: 6 Dec 2001 20:51:32 GMT
X-NewsEditor: ED-1.5.8
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

> I've compiled all the OpenGUI examples with DJGPP, and they run fine
> under windows, but when I try to run them under DOS only mode, they
> all crash...

The crash below is inside CWSDPMI.

The cs is in the GDT (not invalid).  Using the CWSDPMI.MAP file 
from the CWSDPMI build it is says this IP should be tables.asm).
I can use dos "debug" on CWSDPMI.EXE to look at the instruction 
stream near crash point, and I locate those instructions in 
tables.asm.

This is in the entry to
a interrupt 0x31 (call to the DPMI provider) - doing a simulate real
mode interrupt.  It seems to be calling a video interrupt 0x10.
The real mode call structure is at ES:EDI going into the procedure;
at the crash point those values are in DS:ESI (cwsdpmi source).
The limit on DS is 1Mb and it is pointed at the XMS area(?) - but
ESI is clearly outside this limit.  There is a bug in the program
which has modifed DS and not reset it properly.  The call traceback
(did it print?) might tell you where this problem is.

Windows probably just ignores this call or returns an error flag.

> I'm using the cwsdpmi extender (v0.90 r5). Here is the crash:
> 
> Exiting due to signal to SIGSEGV
> General Protection Fault at eip=00003e02
> eax=32450300 ebx=00000010 ecx=00000019
> edx=000000cf esi=00112524 edi=000010c0 
> ebp=000fa440 esp=00fa418 program=c:\hello.exe
> cs: sel=002b invalid
> ds: sel=00bf base=1000000 limit=000fffff
> es: sel=0033 invalid
> fs: sel=008f base=0001dac0 limit=0000ffff
> gs: sel=00c7 base=00000000 limit=0010ffff
> ss: sel=00af base=10000000 limit=0015ffff
> App stack: [000faac4..0007aac4] Exceptn stack: [0007aa20..00078ae0]
> 
> I've also used a different extender (PMODE), and it crashes as well...

As it should, since this is invalid code.  Someone really should 
test things in an environment other than Windows.

- Raw text -


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