diff options
author | Gary Houston <ghouston@arglist.com> | 1997-05-13 04:49:49 +0000 |
---|---|---|
committer | Gary Houston <ghouston@arglist.com> | 1997-05-13 04:49:49 +0000 |
commit | 08fea0882d2bebd6507f6f0894d7754b6b41357b (patch) | |
tree | 27b6693660a37a84df958a11c746c0a3d56fef59 /libguile/script.c | |
parent | 1fbc60b2c3d9af854d5b1afb71cfa7feed5504fd (diff) | |
download | guile-08fea0882d2bebd6507f6f0894d7754b6b41357b.tar.gz |
* script.c (scm_compile_shell_switches): don't append (quit) if
interactive.
(scm_shell): call scm_exit_status and exit on the result of the
evaluation.
Diffstat (limited to 'libguile/script.c')
-rw-r--r-- | libguile/script.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/libguile/script.c b/libguile/script.c index 25eabeb93..ef57ff564 100644 --- a/libguile/script.c +++ b/libguile/script.c @@ -761,12 +761,13 @@ scm_compile_shell_switches (int argc, char **argv) tail = scm_cons (scm_cons (sym_load_user_init, SCM_EOL), tail); tail = scm_cons (scm_cons (sym_top_repl, SCM_EOL), tail); } - - /* After doing all the other actions prescribed by the command line, - quit. */ - tail = scm_cons (scm_cons (sym_quit, SCM_EOL), + else + { + /* After doing all the other actions prescribed by the command line, + quit. */ + tail = scm_cons (scm_cons (sym_quit, SCM_EOL), tail); - + } { /* We want a path only containing directories from SCHEME_LOAD_PATH, SCM_SITE_DIR and SCM_LIBRARY_DIR when searching for the site init @@ -813,7 +814,7 @@ scm_shell (argc, argv) } } - scm_eval_x (scm_compile_shell_switches (argc, argv)); + exit (scm_exit_status (scm_eval_x (scm_compile_shell_switches (argc,argv)))); } |