diff options
author | Jim Kingdon <jkingdon@engr.sgi.com> | 1994-02-02 19:58:31 +0000 |
---|---|---|
committer | Jim Kingdon <jkingdon@engr.sgi.com> | 1994-02-02 19:58:31 +0000 |
commit | 5b3591ab5c099ca985e8aac0ff538dfe36141072 (patch) | |
tree | 0becb3b3fd8f790d0772014197e03e4e9f6d4a27 /gdb/command.c | |
parent | 0f18218b26ddcdd5828c5db5fa415e676f28ca1e (diff) | |
download | gdb-5b3591ab5c099ca985e8aac0ff538dfe36141072.zip gdb-5b3591ab5c099ca985e8aac0ff538dfe36141072.tar.gz gdb-5b3591ab5c099ca985e8aac0ff538dfe36141072.tar.bz2 |
* command.c (shell_escape): Report errors correctly (with error
message from strerror).
Diffstat (limited to 'gdb/command.c')
-rw-r--r-- | gdb/command.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/gdb/command.c b/gdb/command.c index de8bd2a..c302cac 100644 --- a/gdb/command.c +++ b/gdb/command.c @@ -1216,8 +1216,10 @@ shell_escape (arg, from_tty) else execl (user_shell, p, "-c", arg, 0); - fprintf_unfiltered (gdb_stderr, "Exec of shell failed\n"); - exit (0); + fprintf_unfiltered (gdb_stderr, "Cannot execute %s: %s\n", user_shell, + safe_strerror (errno)); + gdb_flush (gdb_stderr); + _exit (0177); } if (pid != -1) |