diff options
author | Arnold D. Robbins <arnold@skeeve.com> | 2022-02-27 20:39:54 +0200 |
---|---|---|
committer | Arnold D. Robbins <arnold@skeeve.com> | 2022-02-27 20:39:54 +0200 |
commit | fc1410099d6ccbb72adb54ecffd0711348706ca4 (patch) | |
tree | d04175556415fff6bcf66f48fc05c4da5f2d4908 /io.c | |
parent | 7acb038bd54f81fb95dac70954e5c1b8ec07a086 (diff) | |
download | egawk-fc1410099d6ccbb72adb54ecffd0711348706ca4.tar.gz egawk-fc1410099d6ccbb72adb54ecffd0711348706ca4.tar.bz2 egawk-fc1410099d6ccbb72adb54ecffd0711348706ca4.zip |
Have cant_happen() give more information.
Diffstat (limited to 'io.c')
-rw-r--r-- | io.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -841,7 +841,7 @@ redirect_string(const char *str, size_t explen, bool not_string, what = "|&"; break; default: - cant_happen(); + cant_happen("invalid redirection type %d", (int) redirtype); } if (do_lint && not_string) lintwarn(_("expression in `%s' redirection is a number"), @@ -1020,7 +1020,7 @@ redirect_string(const char *str, size_t explen, bool not_string, } break; default: - cant_happen(); + cant_happen("invalid redirection type %d", (int) redirtype); } if (mode != NULL) { @@ -1617,7 +1617,7 @@ str2mode(const char *mode) default: ret = 0; /* lint */ - cant_happen(); + cant_happen("invalid open mode \"%s\"", mode); } if (strchr(mode, 'b') != NULL) ret |= O_BINARY; |