mirror of
https://github.com/MidnightCommander/mc
synced 2024-12-23 04:46:55 +03:00
edit/editcmd.c: fix backward search by one symbol.
This commit is contained in:
parent
13b12fdd5b
commit
89bdeb7e34
@ -1126,7 +1126,7 @@ editcmd_find (WEdit *edit, gsize *len)
|
||||
gsize search_end;
|
||||
|
||||
if (edit->replace_backwards) {
|
||||
search_end = edit->curs1;
|
||||
search_end = edit->curs1-1;
|
||||
while ((int) search_start >= 0) {
|
||||
if (search_end - search_start > edit->search->original_len && mc_search_is_fixed_search_str(edit->search))
|
||||
search_end = search_start + edit->search->original_len +1;
|
||||
@ -1136,6 +1136,7 @@ editcmd_find (WEdit *edit, gsize *len)
|
||||
}
|
||||
search_start--;
|
||||
}
|
||||
edit->search->error_str = g_strdup(_(" Search string not found "));
|
||||
} else {
|
||||
return mc_search_run(edit->search, (void *) edit, edit->search_start, edit->last_byte, len);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user