diff options
-rw-r--r-- | shell/ash.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/shell/ash.c b/shell/ash.c index 9681111cc..22c726043 100644 --- a/shell/ash.c +++ b/shell/ash.c @@ -12967,7 +12967,7 @@ trapcmd(int argc UNUSED_PARAM, char **argv UNUSED_PARAM) exitcode = 0; while (*ap) { signo = get_signum(*ap); - if (signo < 0) { + if (signo < 0 || signo >= NSIG) { /* Mimic bash message exactly */ ash_msg("%s: invalid signal specification", *ap); exitcode = 1; |