1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* eval.c (ruby_finalize_0): return the given exit status unless

SystemExit got raised.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4759 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2003-10-14 10:09:39 +00:00
parent 921d595fd4
commit 0b841783b5
2 changed files with 8 additions and 3 deletions

View file

@ -1,3 +1,8 @@
Tue Oct 14 19:09:35 2003 Nobuyoshi Nakada <nobu@ruby-lang.org>
* eval.c (ruby_finalize_0): return the given exit status unless
SystemExit got raised.
Tue Oct 14 11:53:49 2003 Nobuyoshi Nakada <nobu@ruby-lang.org> Tue Oct 14 11:53:49 2003 Nobuyoshi Nakada <nobu@ruby-lang.org>
* intern.h (ruby_stop): never return. * intern.h (ruby_stop): never return.

6
eval.c
View file

@ -1309,8 +1309,8 @@ ruby_options(argc, argv)
void rb_exec_end_proc _((void)); void rb_exec_end_proc _((void));
static int static int
ruby_finalize_0(exp) ruby_finalize_0(ex)
int exp; int ex;
{ {
ruby_errinfo = 0; ruby_errinfo = 0;
PUSH_TAG(PROT_NONE); PUSH_TAG(PROT_NONE);
@ -1326,7 +1326,7 @@ ruby_finalize_0(exp)
VALUE st = rb_iv_get(ruby_errinfo, "status"); VALUE st = rb_iv_get(ruby_errinfo, "status");
return NUM2INT(st); return NUM2INT(st);
} }
return EXIT_SUCCESS; return ex;
} }
void void