delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/11/14/16:30:12

Message-ID: <364DE2CD.70D15563@nt.com>
Date: Sat, 14 Nov 1998 15:06:37 -0500
From: "Ian Chapman" <Ian DOT Chapman DOT ichapman AT nt DOT com>
Organization: Nortel
X-Mailer: Mozilla 4.06 [en] (Win95; I)
MIME-Version: 1.0
To: djgpp AT delorie DOT com
Subject: Re: I cant get spawning to work
References: <199811071756 DOT MAA07051 AT indy DOT delorie DOT com>
Reply-To: djgpp AT delorie DOT com

Hi DJ,
	I had the same problem and I gave up and used I think it was system. 
I'd never have guessed the double "myexe.exe" from info.  Guess I need
reading lessons.

		Regards Ian.

DJ Delorie wrote:
> 
> > {  if (spawnl(P_WAIT, "", "myexe.exe")==-1)
> 
> The second argument is the program to run.  Obviously, "" won't work.
> The third argument, where you are putting the program name, is only
> used to generate the program's argv[0] and may be anything you want.
> In addition, spawnl() requires that the final argument be NULL,
> so that it knows where the end of the list of parameters is.  Your
> example should be like this:
> 
>         spawnl(P_WAIT, "myexe.exe", "myexe.exe", NULL)

- Raw text -


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