vi: issue a warning on failure to find a character
When a search for a character within a line fails issue a warning. function old new delta ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 0/0 up/down: 0/0) Total: 0 bytes Signed-off-by: Ron Yorston <rmy@pobox.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
parent
6220b4d531
commit
99fb5f2144
@ -1809,8 +1809,10 @@ static void dot_to_char(int cmd)
|
|||||||
do {
|
do {
|
||||||
do {
|
do {
|
||||||
q += dir;
|
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;
|
return;
|
||||||
|
}
|
||||||
} while (*q != last_search_char);
|
} while (*q != last_search_char);
|
||||||
} while (--cmdcnt > 0);
|
} while (--cmdcnt > 0);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user