Mail Archives: djgpp/1998/11/14/16:30:12
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 -