chiark / gitweb /
git-debrebase: parsecommit: fix Ix to not be off-by-one
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Tue, 30 Jan 2018 19:07:24 +0000 (19:07 +0000)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sat, 16 Jun 2018 11:25:49 +0000 (12:25 +0100)
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
git-debrebase

index f254ddc9ae91ad77cb71158f80522c7c2617b064..d32c5f30a643baaed39df5f27ad8814573e7cfdd 100755 (executable)
@@ -327,7 +327,7 @@ sub parsecommit ($;$) {
 
     foreach my $ph (@ph) {
        push @$p_ref, {
-            Ix => $#$p_ref,
+            Ix => scalar @$p_ref,
             CommitId => $ph,
         };
     }