From: dcasale AT my-deja DOT com Newsgroups: comp.os.msdos.djgpp Subject: Re: GP fault on a new -- why? Date: Thu, 08 Feb 2001 18:40:37 GMT Organization: Deja.com Lines: 60 Message-ID: <95up73$63a$1@nnrp1.deja.com> References: NNTP-Posting-Host: 199.249.234.30 X-Article-Creation-Date: Thu Feb 08 18:40:37 2001 GMT X-Http-User-Agent: Mozilla/4.0 (compatible; MSIE 5.5; Windows 98) X-Http-Proxy: 1.1 x67.deja.com:80 (Squid/1.1.22) for client 199.249.234.30 X-MyDeja-Info: XMYDJUIDdcasale To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com In article , djgpp AT delorie DOT com wrote: > > On Wed, 7 Feb 2001 dcasale AT my-deja DOT com wrote: > > > Okay, here's all it gives me. No stack trace or anything. > > > > General Protection Fault at eip-3af9d; flags=3046 > > eax=00043406 ebx=000100af ecx=00af00a7 edx=0000001c esi=00af00bf > > edi=00000000 ebp=0004342c esp=0000227a cs=a7 ds=a7 es=af fs=bf gs=bf > > ss=33 error=0000 > > You will see in section 12.2 that this message comes from CWSDPMI. It > means you crashed the machine so badly that CWSDPMI aborted itself. Section 12.2 of the FAQ only referred to CWSDPMI in connection with a _Page Fault_. This was a _General Protection Fault_. If the FAQ doesn't specifically say that General Protection Faults can also come from CWSDPMI, how am I supposed to know? > > I don't know if this'll be any help, tho... > > It's of _great_ help. > > The code which crashes is at 0x3af9d. Can you see what's there? One > way is to load the program into GDB, then type "list *0x3af9d". You > should see the listing of several source lines around the point where > it crashes. If "list" doesn't work, try "disassemble 0x3af9d", which > should at least say inside what function did it happen. I disassembled it, and it says it's from __djgpp_exception_table. Specifically, it's crashing on the following line (excerpted from src/libc/go32/excepn.S): exception_handler: pushl %ebx pushl %ds .byte 0x2e /* CS: */ cmpb $0, forced je not_forced call limitFix .byte 0x2e /* CS: */ movzbl forced,%ebx movl %ebx,8(%esp) /* replace EXCEPNO */ not_forced: movw %cs:___djgpp_our_DS, %ds movl $0x10000, forced <----- /* its zero now, flag inuse */ movl $exception_state, %ebx I still have no idea what this means. I'm guessing that it crashed while trying to throw an exception, but that doesn't tell me what I need to do to fix the problem. *shrugs* Damon Casale, damon AT WRONG DOT redshift DOT com (remove the obvious) "Number five alive! No disassemble." -- Number 5, "Short Circuit" Sent via Deja.com http://www.deja.com/