]> granicus.if.org Git - graphviz/commitdiff
Fix bug 1429.
authorerg <devnull@localhost>
Fri, 22 Aug 2008 18:24:19 +0000 (18:24 +0000)
committererg <devnull@localhost>
Fri, 22 Aug 2008 18:24:19 +0000 (18:24 +0000)
lib/common/utils.c

index c1dd003d1c725baa82e48b9ca0ba8110e384c8c8..8d003b5267534776d8b42ed49a6ca541e9a83675 100644 (file)
@@ -803,6 +803,12 @@ void compute_bb(graph_t * g)
 #endif
     int i, j;
 
+    if ((agnnodes(g) == 0) && (GD_n_cluster(g) ==0)) {
+       bb.LL = pointfof(0, 0);
+       bb.UR = pointfof(0, 0);
+       return;
+    }
+
     bb.LL = pointfof(INT_MAX, INT_MAX);
     bb.UR = pointfof(-INT_MAX, -INT_MAX);
     for (n = agfstnode(g); n; n = agnxtnode(g, n)) {