← Commit list

99fb5f214

Ron Yorston
Ron Yorston
2021-04-11
SUCCESS Duration: 152s

Subject

vi: issue a warning on failure to find a character

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 →

editors/vi.c+3 -1
@@ -1809,8 +1809,10 @@ static void dot_to_char(int cmd)
do {
do {
q += dir;
- if ((dir == FORWARD ? q > end - 1 : q < text) || *q == '\n')
+ if ((dir == FORWARD ? q > end - 1 : q < text) || *q == '\n') {
+ indicate_error();
return;
+ }
} while (*q != last_search_char);
} while (--cmdcnt > 0);