]> granicus.if.org Git - graphviz/commitdiff
sccmap.c: return an unsigned type from 'visit'
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Sat, 13 Nov 2021 02:59:48 +0000 (18:59 -0800)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Fri, 19 Nov 2021 01:52:27 +0000 (17:52 -0800)
Squashes a -Wsign-conversion warning.

The `val` member of `Agnodeinfo_t` is unsigned and all uses of this function
store the return value in an unsigned. So it seems this function always should
have been declared as returning an unsigned.

cmd/tools/sccmap.c

index 95cf1459bd161e61867ffceabbb7c21cd79247ea..d5dc010d8856f0bea1f265f9703a960e90378f9f 100644 (file)
@@ -139,7 +139,7 @@ static void nodeInduce(Agraph_t * g, Agraph_t* map)
     }
 }
 
-static int visit(Agnode_t * n, Agraph_t * map, Stack * sp, sccstate * st)
+static unsigned visit(Agnode_t * n, Agraph_t * map, Stack * sp, sccstate * st)
 {
     unsigned int m, min;
     Agnode_t *t;