spelling: pass the correct position of the cursor
When starting to replace misspelled words, pass the actual position of the cursor instead of the position of the first found occurrence, so that the cursor position will be updated for changed lengths. This fixes https://savannah.gnu.org/bugs/?47834.master
parent
cc0a3d8490
commit
937c47898a
|
@ -2449,8 +2449,7 @@ bool do_int_spell_fix(const char *word)
|
|||
/* If a replacement was given, go through all occurrences. */
|
||||
if (proceed && strcmp(word, answer) != 0) {
|
||||
openfile->current_x--;
|
||||
do_replace_loop(TRUE, openfile->current,
|
||||
&openfile->current_x, word);
|
||||
do_replace_loop(TRUE, current_save, ¤t_x_save, word);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue