← Commit list

e9aba3e7e

Denys Vlasenko
Denys Vlasenko
2017-07-01
SUCCESS Duration: 144s

Subject

ash: fix 'trap - 65'

Binary

No binary (build failed)

Architecture & Compiler Flags

Architecture: x86_64-linux-gnu Compiler: gcc (Ubuntu 11.4.0-1ubuntu1~22.04.3) 11.4.0

—

Build Log

(log yok)

Commit Diff GitHub →

shell/ash.c+1 -1
@@ -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;