]> granicus.if.org Git - graphviz/commitdiff
PrintRect: move definition of i closer to its use and use a better type
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Wed, 24 Mar 2021 03:57:12 +0000 (20:57 -0700)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Wed, 31 Mar 2021 00:14:01 +0000 (17:14 -0700)
lib/label/rectangle.c

index 65b46d86ae2576878e1dddf361ea25216e6ed899..881165253db99879afb2a0a6144ee41c2bca24dc 100644 (file)
@@ -50,10 +50,9 @@ Rect_t NullRect()
 -----------------------------------------------------------------------------*/
 void PrintRect(Rect_t * r)
 {
-    int i;
     assert(r);
     fprintf(stderr, "rect:");
-    for (i = 0; i < NUMDIMS; i++)
+    for (size_t i = 0; i < NUMDIMS; i++)
        fprintf(stderr, "\t%d\t%d\n", r->boundary[i],
                r->boundary[i + NUMDIMS]);
 }