Commits

bbarry  committed 4982e91

bug: parent[0] may not exist under certain circumstances

  • Participants
  • Parent commits 64f7e42

Comments (0)

Files changed (1)

         if date:
             fp.write('# Date %d %d\n' % date)
         parents = [p.node() for p in ctx.parents() if p]
-        fp.write('# Parent  %s\n' % hex(parents[0]))
+        if parents:
+            fp.write('# Parent  %s\n' % hex(parents[0]))
         if msg:
             if not isinstance(msg, str):
                 msg = '\n'.join(msg)