collectctl: compare pointer with NULL not 0
authorRuben Kerkhof <ruben@rubenkerkhof.com>
Sat, 16 Apr 2016 11:46:07 +0000 (13:46 +0200)
committerRuben Kerkhof <ruben@rubenkerkhof.com>
Sat, 16 Apr 2016 11:59:12 +0000 (13:59 +0200)
Found with coccinelle

src/collectdctl.c

index 7d3cbce..ee11c45 100644 (file)
@@ -483,7 +483,7 @@ static int putval (lcc_connection_t *c, int argc, char **argv)
 
       values_len = 0;
       value = tmp;
-      while (value != 0) {
+      while (value != NULL) {
         char *dot, *endptr;
 
         tmp = strchr (value, (int)':');