do_replace()
- Blank out last_replace properly again just before displaying
the "Replace" prompt. (DLR, found by Mike Frysinger)
+ - Remove unnecessary renumber(). (DLR)
- winio.c:
- edit_scroll()
+ edit_scroll(), edit_refresh()
- Clean up and simplify. (DLR)
do_statusbar_next_word()
- Rework to be more like do_statusbar_prev_word(), to avoid a
assert(fileptr != fileptr->next);
for (; fileptr != NULL; fileptr = fileptr->next)
- fileptr->lineno = line++;
+ fileptr->lineno = ++line;
}
/* Partition a filestruct so it begins at (top, top_x) and ends at (bot,
openfile->current_x = begin_x;
openfile->placewewant = pww_save;
- renumber(openfile->fileage);
edit_refresh();
if (numreplaced >= 0)
fprintf(stderr, "edit_refresh(): edittop->lineno = %ld\n", (long)openfile->edittop->lineno);
#endif
- while (nlines < editwinrows) {
+ while (nlines < editwinrows && foo != NULL) {
update_line(foo, (foo == openfile->current) ?
openfile->current_x : 0);
- nlines++;
- if (foo->next == NULL)
- break;
foo = foo->next;
+ nlines++;
}
while (nlines < editwinrows) {
blank_line(edit, nlines, 0, COLS);