I'd like to know the meaning of this exit code :
( c++ program compiled with vc++)
The conventions depend on the system, and the actual exit code
depends on the program which exited. All the standard says is
that 0 and EXIT_SUCCESS will map to something the system will
understand as success, and that EXIT_FAILURE will map to
something the system understands as failure. Most systems have
more complete conventions, however, some of which may require
actual mapping. (On at least one system, even codes meant
failure, and odd success---the C/C++ runtime library had to map
0 to some other odd number.)
As a simply example, the Unix conventions are that if the value
returned by the application (when returning from main, or
calling exit) is 0, modulo 256, it is success, and all other
values are failure. But that convention is not universally used
by all Unix applications: grep, for example, will return 1 if
there is no match, and 2 for failure. (Depending on what you
are doing, no match may or may not be considered a failure).
And if the program is terminated by a signal (segment violation,
for example), the shell will simulate an exit code of the signal
number + 128 (which means that well behaved applications will
not return exit codes greater than 127).
I'm far less familiar with Windows, but I think it returns the
value without mapping (as opposed to the modulo 256 which Unix
uses); I'm also unsure of what it does if the process was
terminated. There's also a possibility that the program was
generated with a pre-standard compiler, and simply fell off the
end of main, effectively generating a random exit code. (The
C++ standard requires an exit code of 0 in such cases, but C
doesn't, and pre-standard C++ compilers likely won't guarantee 0
either.)
Is there a table for exit codes ?
There should be one in the documentation of the program which
generated it. You might want to check out the system
documentation as well, in order to know what the general
conventions are.