Skip to content

Commit

Permalink
Update lineno for untracked files (#1193)
Browse files Browse the repository at this point in the history
Fixes #1192
  • Loading branch information
110y authored Jun 5, 2022
1 parent dfe3df0 commit f52f003
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/diff.c
Original file line number Diff line number Diff line change
Expand Up @@ -835,6 +835,7 @@ diff_common_select(struct view *view, struct line *line, const char *changes_msg
view->env->lineno_old = diff_get_lineno(view, line, true);
view->env->blob[0] = 0;
} else {
view->env->lineno = view->env->goto_lineno = (line - view->line) + 1;
string_ncopy(view->ref, view->ops->id, strlen(view->ops->id));
}
}
Expand Down

0 comments on commit f52f003

Please sign in to comment.