On 16 June 2011 12:32, Francis GALIEGUE <f...@one2team.com> wrote:
> On Thu, Jun 16, 2011 at 13:30, sebb <seb...@gmail.com> wrote:
> [...]
>>>
>>> It's up to main() to call System.exit(), so how is that a problem?
>>
>> If the exit code is not passed to the OS, but is merely a method
>> return code, then of course it's not a problem.
>>
>> But I understood the term "exit code" to mean the code returned to the
>> OS through System.exit().
>>
>
> You lost me. System.exit() acts at the JVM level anyway, therefore the
> process level. Don't we talk about the same thing?

The value passed to System.exit(int) is passed to the OS.

In Unix systems, 0 means success and anything else is generally not success.

OpenVMS behaves differently, as already noted.
If a process returns an error or fatal code to VMS, then by default
the script running it will exit with an error.

So changing the OS exit code can affect existing users.

The point is that exit codes are not portable across OSes; the most
one can hope for is sucess or failure indication.

>
> --
> Francis Galiegue
> ONE2TEAM
> Ingénieur système
> Mob : +33 (0) 683 877 875
> Tel : +33 (0) 178 945 552
> f...@one2team.com
> 40 avenue Raymond Poincaré
> 75116 Paris
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to