]> granicus.if.org Git - graphviz/commitdiff
osage layout: remove shadowing of 'p'
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Thu, 8 Sep 2022 03:36:45 +0000 (20:36 -0700)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Fri, 9 Sep 2022 14:45:06 +0000 (07:45 -0700)
lib/osage/osageinit.c

index 3d0028b7cc7cf3d9418345a84251240ff18e4724..3e8191a6aab72df7eaad56860f546e6475c945f9 100644 (file)
@@ -196,18 +196,17 @@ layout (Agraph_t* g, int depth)
     }
 
     if (GD_label(g)) {
-        pointf p;
         double d;
 
-        p = GD_label(g)->dimen;
+        pointf pt = GD_label(g)->dimen;
        if (total == 0) {
             rootbb.LL.x = 0;
             rootbb.LL.y = 0;
-            rootbb.UR.x = p.x;
-            rootbb.UR.y = p.y;
+            rootbb.UR.x = pt.x;
+            rootbb.UR.y = pt.y;
 
        }
-        d = p.x - (rootbb.UR.x - rootbb.LL.x);
+        d = pt.x - (rootbb.UR.x - rootbb.LL.x);
         if (d > 0) {            /* height of label is added below */
             d /= 2;
             rootbb.LL.x -= d;