Skip to content

Commit

Permalink
submodule summary: do not shift a non-existent positional variable
Browse files Browse the repository at this point in the history
When "git submodule summary" is run without any argument, we default to
compare the state of index with the HEAD, but tried to shift out $1 that
does not exist (and worse yet, we didn't use it).

Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Jeff King authored and Junio C Hamano committed Mar 3, 2010
1 parent 3deea89 commit caa9c3c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion git-submodule.sh
Original file line number Diff line number Diff line change
Expand Up @@ -556,7 +556,7 @@ cmd_summary() {
if rev=$(git rev-parse -q --verify --default HEAD ${1+"$1"})
then
head=$rev
shift
test $# = 0 || shift
elif test -z "$1" -o "$1" = "HEAD"
then
return
Expand Down

0 comments on commit caa9c3c

Please sign in to comment.