Skip to content

Commit

Permalink
rm: do not set a variable twice without intermediate reading.
Browse files Browse the repository at this point in the history
Just the next line assigns a non-null value to seen.

Signed-off-by: Stefan Beller <stefanbeller@googlemail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Stefan Beller authored and Junio C Hamano committed Jul 23, 2013
1 parent db6a6ad commit 4838c81
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion builtin/rm.c
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,6 @@ int cmd_rm(int argc, const char **argv, const char *prefix)
parse_pathspec(&pathspec, 0, PATHSPEC_PREFER_CWD, prefix, argv);
refresh_index(&the_index, REFRESH_QUIET, &pathspec, NULL, NULL);

seen = NULL;
seen = xcalloc(pathspec.nr, 1);

for (i = 0; i < active_nr; i++) {
Expand Down

0 comments on commit 4838c81

Please sign in to comment.