Skip to content

Commit 3406554

Browse files
agrngitster
authored andcommitted
sequencer: update `done_nr' when skipping commands in a todo list
In a todo list, `done_nr' is the number of commands that were executed or skipped, but skip_unnecessary_picks() did not update it. This variable is mostly used by command prompts (ie. git-prompt.sh and the like). As in the previous commit, this inconsistent behaviour is not a problem yet, but it would start to matter at the end of this series the same reason. Signed-off-by: Alban Gruin <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 8638114 commit 3406554

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

sequencer.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5054,6 +5054,7 @@ static int skip_unnecessary_picks(struct repository *r,
50545054
MOVE_ARRAY(todo_list->items, todo_list->items + i, todo_list->nr - i);
50555055
todo_list->nr -= i;
50565056
todo_list->current = 0;
5057+
todo_list->done_nr += i;
50575058

50585059
if (is_fixup(peek_command(todo_list, 0)))
50595060
record_in_rewritten(base_oid, peek_command(todo_list, 0));

0 commit comments

Comments
 (0)