]> granicus.if.org Git - graphviz/commitdiff
colorxlate: remove some unnecessary bracketing
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Sun, 29 Aug 2021 23:18:41 +0000 (16:18 -0700)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Sat, 4 Sep 2021 02:26:35 +0000 (19:26 -0700)
cmd/tools/colxlate.c

index bea203e6ee40743919e08510085d0a2b5ffb577a..e7834547f4b0e7768172b8df5e98b68c292e3add 100644 (file)
@@ -72,8 +72,7 @@ char *colorxlate(char *str, char *buf)
     char *p;
     hsbcolor_t fake;
 
-    if ((last == NULL)
-       || (strcmp(last->name, str))) {
+    if (last == NULL || strcmp(last->name, str)) {
        fake.name = (char *) canoncolor(str, canon);
        last = bsearch(&fake, color_lib, sizeof(color_lib) / sizeof(hsbcolor_t),
                       sizeof(fake), colorcmpf);