Kernel#exit! without arg causes wrong process exit code
-------------------------------------------------------
Key: JRUBY-5431
URL: http://jira.codehaus.org/browse/JRUBY-5431
Project: JRuby
Issue Type: Bug
Components: Core Classes/Modules
Affects Versions: JRuby 1.5.6
Reporter: Anders Bengtsson
Exiting with Kernel#exit! gives a successful (0) exit value for the process,
unlike MRI with gives unsuccessful (1). This breaks some shell scripts that use
ruby.
With MRI (1.9.2p136):
> ruby -e 'exit!'; echo $?
1
> ruby -e 'exit!(true)'; echo $?
0
> ruby -e 'exit!(false)'; echo $?
1
But with JRuby:
> ruby -e 'exit!'; echo $?
0
> ruby -e 'exit!(true)'; echo $?
0
> ruby -e 'exit!(false)'; echo $?
1
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email