git-tracker: fix multi-commit tracking
authorJohannes Berg <johannes.berg@intel.com>
Thu, 18 Apr 2013 11:58:09 +0000 (13:58 +0200)
committerJohannes Berg <johannes.berg@intel.com>
Thu, 18 Apr 2013 11:59:01 +0000 (13:59 +0200)
Fix a bug with multiple commits: the first commit in
a series was always treated as "multiple" because it
had no correct parent recorded in the dictionary.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
devel/git-tracker.py

index 0771703c602a826bd2c8c04f5032c79b29578f1c..9edc95cfb3b962528fdfbe3661c696cbb7dc6d6f 100755 (executable)
@@ -214,7 +214,7 @@ if __name__ == '__main__':
                         print "too many commits (%d)!" % len(commits)
                         sys.exit(10)
                     prev_commits = {}
-                    p = None
+                    p = prev
                     for commit in commits:
                         prev_commits[commit] = p
                         p = commit