]> granicus.if.org Git - graphviz/commitdiff
Resolved two warnings in arrows.c
authorErwin Janssen <erwinjanssen@outlook.com>
Thu, 1 Sep 2016 18:01:01 +0000 (20:01 +0200)
committerErwin Janssen <erwinjanssen@outlook.com>
Thu, 1 Sep 2016 18:01:01 +0000 (20:01 +0200)
The local variable `namelen` is always positive, so the type `size_t` could be used.

lib/common/arrows.c

index 989eb9e55a1fefa0380a332f511cff9d6be8bcda..6f4f340dafc80925fb5789bfb96e6aa8a387b111 100644 (file)
@@ -138,7 +138,7 @@ static arrowtype_t Arrowtypes[] = {
 static char *arrow_match_name_frag(char *name, arrowname_t * arrownames, int *flag)
 {
     arrowname_t *arrowname;
-    int namelen = 0;
+    size_t namelen = 0;
     char *rest = name;
 
     for (arrowname = arrownames; arrowname->name; arrowname++) {