summaryrefslogtreecommitdiff
path: root/ruby.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1998-05-08 09:38:16 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1998-05-08 09:38:16 +0000
commitdde6b7dd06268221b3e6931ca7582b2da7b52403 (patch)
tree0bdfde93b61d81649427e054af09fc3a7660a82d /ruby.c
parent71ad3aa4ffdf0c5e8b387bb9c258ce1b66d6836e (diff)
pack/unpack unsigned
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/v1_1r@204 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ruby.c')
-rw-r--r--ruby.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/ruby.c b/ruby.c
index 9e8dedd..ac5117f 100644
--- a/ruby.c
+++ b/ruby.c
@@ -567,7 +567,7 @@ load_file(fname, script)
if (script) {
rb_define_global_const("DATA", f);
}
- else if (f != rb_stdin) {
+ if (f != rb_stdin) {
io_close(f);
}
}
@@ -783,7 +783,7 @@ ruby_process_options(argc, argv)
{
origargc = argc; origargv = argv;
ruby_script(argv[0]); /* for the time being */
- rb_argv0 = str_taint(str_new2(argv[0]));
+ rb_argv0 = rb_progname;
#if defined(USE_DLN_A_OUT)
dln_argv0 = argv[0];
#endif
@@ -801,12 +801,12 @@ ruby_process_options(argc, argv)
if (do_loop) {
yywhile_loop(do_line, do_split);
}
- if (e_tmpname) {
- unlink(e_tmpname);
- e_tmpname = NULL;
- }
if (e_fp) {
fclose(e_fp);
e_fp = NULL;
}
+ if (e_tmpname) {
+ unlink(e_tmpname);
+ e_tmpname = NULL;
+ }
}