Date: Thu, 13 Nov 1997 13:17:10 +0200 (IST) From: Eli Zaretskii To: Oon Lin cc: djgpp AT delorie DOT com Subject: Re: fopen() gives Segmentation Fault. Help ? In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Precedence: bulk On Thu, 13 Nov 1997, Oon Lin wrote: > I'm having problem using fopen() in DJGPP. What happened is that I made a > first fopen() call to open a file for reading only and that works > fine..and when I call the second fopen() (after I closed the first > fopen()) it just gives me General Protection Fault with Segmentation > violation .... anybody has any ideas ?? Is the posted source *exactly* the same source that causes this on your machine? If not, please post the precise source that doesn't work. The source you posted is perfectly correct. Please also post the stack dump printed when the program crashes. It might include crucial hints to the cause of the problem.