← Commit list

07f7ea70e

Denys Vlasenko
Denys Vlasenko
2014-09-08
SUCCESS Duration: 150s

Subject

ash: fix off-by-one in "jobs %4" handling. closes 7310

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
@@ -3647,7 +3647,7 @@ getjob(const char *name, int getctl)
if (is_number(p)) {
num = atoi(p);
- if (num < njobs) {
+ if (num <= njobs) {
jp = jobtab + num - 1;
if (jp->used)
goto gotit;