Compare int value against 0, not '\0', for consistency.
authormillert <millert@openbsd.org>
Tue, 19 Sep 2023 01:14:05 +0000 (01:14 +0000)
committermillert <millert@openbsd.org>
Tue, 19 Sep 2023 01:14:05 +0000 (01:14 +0000)
usr.bin/awk/b.c

index abe6750..64284ab 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: b.c,v 1.40 2023/09/18 23:33:21 millert Exp $  */
+/*     $OpenBSD: b.c,v 1.41 2023/09/19 01:14:05 millert Exp $  */
 /****************************************************************
 Copyright (C) Lucent Technologies 1997
 All Rights Reserved
@@ -533,7 +533,7 @@ int first(Node *p)  /* collects initially active leaves of p into setvec */
                        setvec[lp] = 1;
                        setcnt++;
                }
-               if (type(p) == CCL && (*(int *) right(p)) == '\0')
+               if (type(p) == CCL && (*(int *) right(p)) == 0)
                        return(0);              /* empty CCL */
                return(1);
        case PLUS: