delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2004/09/18/06:26:25

X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f
Date: Sat, 18 Sep 2004 13:20:44 +0300
From: "Eli Zaretskii" <eliz AT gnu DOT org>
Sender: halo1 AT zahav DOT net DOT il
To: djgpp AT delorie DOT com
Message-ID: <01c49d69$Blat.v2.2.2$4dafa4a0@zahav.net.il>
X-Mailer: emacs 21.3.50 (via feedmail 8 I) and Blat ver 2.2.2
In-reply-to: <cif5n1$79u$1@nsnmpen3-gest.nuria.telefonica-data.net> (message
from =?ISO-8859-1?Q?Rafael_Garc=EDa?= on Fri, 17 Sep 2004 19:06:34
+0200)
Subject: Re: calling unzip32 from C program
References: <ciesel$60c$1 AT nsnmpen3-gest DOT nuria DOT telefonica-data DOT net> <2r0dd4F14ift1U1 AT uni-berlin DOT de> <cif5n1$79u$1 AT nsnmpen3-gest DOT nuria DOT telefonica-data DOT net>
Reply-To: djgpp AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

> From: =?ISO-8859-1?Q?Rafael_Garc=EDa?= <rafael_no_spam_no_ AT geninfor DOT com>
> Date: Fri, 17 Sep 2004 19:06:34 +0200
> 
> See: if I call unzip32 from console or from a BAT executed from
> console, it returns 0; if I call unzip32 from a C program, via
> system(), or from a BAT file launched from a C program, it returns 1

As I explained in my other message here, the DJGPP implementation of
`system' avoids calling the shell as much as possible, and instead
tries to find and invoke the program directly.  If it succeeds to find
the program, then its exit status will become the return value of
`system', whereas the shell is always returning 0.

- Raw text -


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