Commit da564385 authored by Benno Schulenberg's avatar Benno Schulenberg
Browse files

replacing: start at the region's edge instead of one step before it

After the changes to the search routine, it is no longer necessary to
take one step back before starting a replacement session.

This fixes https://savannah.gnu.org/bugs/?50147.
No related merge requests found
Showing with 1 addition and 1 deletion
+1 -1
......@@ -597,7 +597,7 @@ ssize_t do_replace_loop(const char *needle, bool whole_word_only,
/* Start either at the top or the bottom of the marked region. */
if (!ISSET(BACKWARDS_SEARCH)) {
openfile->current = top;
openfile->current_x = (top_x == 0 ? 0 : top_x - 1);
openfile->current_x = top_x;
} else {
openfile->current = bot;
openfile->current_x = bot_x;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment