Mail Archives: djgpp/1997/02/13/09:30:06
marsel AT ktb DOT net wrote:
>
> says: Program exit code: -1(0xffffffff). Can anybody help me with it?
At first; This message informs you only about the return value from
your program. (If you have ever written a batch file, there it was
called ERRORLEVEL).
About the value -1 I can say, that there are several reasons to
produce this.
1) Your program has somewhere an error produced, which results
in a 'exit(-1)'. This may happen for a GPF for instance.
2) You have declared your main function as 'void main()' or you
forgot to put an 'return VALUE;' statement and so
the return value of that function (which is the exit code of
your program when it runs normally) is undefined in a C program
(in C++ the compiler generates automaticaly a return value 0).
Robert
--
*****************************************************************
* Robert Hoehne, Fakultaet fuer Mathematik, TU-Chemnitz-Zwickau *
* Post: Am Berg 3, D-09573 Dittmannsdorf *
* e-Mail: Robert DOT Hoehne AT Mathematik DOT TU-Chemnitz DOT DE *
* WWW: http://www.tu-chemnitz.de/~rho *
*****************************************************************
- Raw text -