graphlog: add assertion for allowed n_column_diff range
authorPeter Arrenbrecht <peter.arrenbrecht@gmail.com>
Wed, 12 Nov 2008 16:32:21 +0100
changeset 7356 eee5b7b9c5d2
parent 7355 fac7e9070a19
child 7357 6eb38b2dca6c
graphlog: add assertion for allowed n_column_diff range
hgext/graphlog.py
--- a/hgext/graphlog.py	Wed Nov 12 16:32:35 2008 +0100
+++ b/hgext/graphlog.py	Wed Nov 12 16:32:21 2008 +0100
@@ -195,6 +195,7 @@
     prev_node_index = 0
     for (node_ch, node_lines, node_index, edges, n_columns, n_columns_diff) in grapher:
 
+        assert -2 < n_columns_diff < 2
         if n_columns_diff == -1:
             # Transform
             #