]> granicus.if.org Git - graphviz/commitdiff
sccmap.c: use libc support to define 'INF'
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Sat, 13 Nov 2021 03:00:46 +0000 (19:00 -0800)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Fri, 19 Nov 2021 01:52:33 +0000 (17:52 -0800)
Squashes a -Wconversion warning.

cmd/tools/sccmap.c

index d5dc010d8856f0bea1f265f9703a960e90378f9f..ef13244aee07a5bcb11cd01a06050b3e76bdcb63 100644 (file)
@@ -21,6 +21,7 @@
  */
 #include "config.h"
 
+#include <limits.h>
 #include <stdio.h>
 #include <stdlib.h>
 #ifdef HAVE_UNISTD_H
@@ -31,7 +32,7 @@
 
 #include <getopt.h>
 
-#define INF ((unsigned int)(-1))
+#define INF UINT_MAX
 
 typedef struct Agraphinfo_t {
     Agrec_t h;