delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/05/07/05:47:08

From: leetonks AT hotmail DOT com
Newsgroups: comp.os.msdos.djgpp
Subject: DJGPP 2.01 spawnvp problem......
Date: Thu, 07 May 1998 04:20:44 -0600
Organization: Deja News - The Leader in Internet Discussion
Lines: 38
Message-ID: <6irudc$34i$1@nnrp1.dejanews.com>
Reply-To: l DOT tonks AT no DOT spam DOT please DOT pindar DOT com
NNTP-Posting-Host: 194.193.96.250
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

Hi!

I've recently compiled a program which was previously written in Borland C++
3.1 in DJGPP 2.01 and have come across a problem which I don't seem to be able
to fix.

The program runs another DJGPP program using a call to spawnvp, but this call
just doesn't want to work for some reason.

The line is :
result=spawnvp(P_WAIT,prog,par);

where prog is a null-terminated char array and par is an array of pointers to
the parameters to be passed.

When this runs, the program immediately falls over with a GPF error :

Exiting due to signal SIGSEGV
General Protection Fault at eip=etc,etc,etc.

I'm compiling for DOS and running under both DOS 6.22 and Windows NT 4 - the
error is the same either way. Under DOS, an extra error value is reported on
the screen which says it is error 4. According to the DJGPP docs this is
EACCES - Permission Denied. What does this mean? :-(

I'm 99% confident there isn't a problem in the code as it worked just fine
under Borland. I've also tried recompiling libc to allow 50 open files as
opposed to 20 (as mentioned in a similar but different problem on the DJGPP
bug database) and that hasn't done any good either.

Does ANYONE know what's going on? Any help very greatly appreciated.



Lee.

-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/   Now offering spam-free web-based newsreading

- Raw text -


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