Date: Mon, 22 Feb 1999 13:34:57 +0200 (IST) From: Eli Zaretskii X-Sender: eliz AT is To: Laurynas Biveinis cc: djgpp AT delorie DOT com Subject: Re: Help : cannot switch screen mode In-Reply-To: <199902212039.PAA00064@delorie.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Reply-To: djgpp AT delorie DOT com On Sun, 21 Feb 1999, Laurynas Biveinis wrote: > #include > #include > > int main(void) > { > __dpmi_regs regs; > regs.x.ax = 0x0013; > _dpmi_int(0x10, ®s); > getch(); > regs.x.ax = 0x0003; > _dpmi_int(0x10, ®s); > return 0; > }; Is this the exact source you compiled? I don't think so: there's no function _dpmi_int in the DJGPP's library, it's __dpmi_int (with two leading underscores). So this source should not even compile. Please post the *exact* source that you compiled, and the exact command line you used to compile and link it. > But it doesn't work: on first _dpmi_int call I get: > > Exiting due to signal SIGSEGV > General Protection Fault at eip=0000002d This EIP does NOT point to __dpmi_int. Please run `symify' on the traceback (see section 9.2 of the DJGPP FAQ list) and post the results. Tracebacks without the symbols lack a lot of info that helps to diagnose such problems. > cs: sel=01f7 base=833ff000 limit=0005ffff > ds: sel=01ff base=833ff000 limit=0005ffff This indicates that you probably ran your program from another DJGPP program (like RHIDE), or from Windows. Is that true? If so, please try running it from the DOS command prompt under plain DOS, and if it crashes, post the traceback printed by it.