| delorie.com/archives/browse.cgi | search |
| X-Authentication-Warning: | delorie.com: mail set sender to djgpp-bounces using -f |
| From: | Cesar Rabak <crabak AT acm DOT org> |
| Newsgroups: | comp.os.msdos.djgpp |
| Subject: | Re: calling unzip32 from djgpp |
| Date: | Mon, 20 Sep 2004 09:26:03 -0300 |
| Lines: | 31 |
| Message-ID: | <414ECC5B.7000802@acm.org> |
| References: | <42da7100 DOT 0409200153 DOT 6cb9560f AT posting DOT google DOT com> |
| Mime-Version: | 1.0 |
| X-Trace: | news.uni-berlin.de Z/FCLLHSItKSX2+xgeYZTAH+Tnd/vT3oEWMjtXYVqBqAwaiwg= |
| User-Agent: | Mozilla/5.0 (Windows; U; Windows NT 5.1; pt-BR; rv:1.0.2) Gecko/20030208 Netscape/7.02 |
| X-Accept-Language: | pt-br, pt |
| To: | djgpp AT delorie DOT com |
| DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
| Reply-To: | djgpp AT delorie DOT com |
rafael garcia escreveu:
> I have not explained well, sorry.
>
> The thing I cannot understand is why unzip32.exe change its return
> value when called from another DJGPP exe. I can get its return value
> before going back to system() code, in the BAT file:
>
> @unzip32 -o %1
> @if errorlevel 1 echo UNZIP32 COULD NOT TERMINATE CORRECTLY
> @rem I don't know why this message appears only if called
> @rem from system() but not from console
>
If I call the above bat file from a C program as follows:
#include <stdlib.h>
int
main(void)
{
system("prueba.bat");
return 0;
}
I get the same results be it calling the bat file ("prueba.bat") or the
compiled program.
HTH
--
Cesar Rabak
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |