]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/gc: silence clang warning
authorRuss Cox <rsc@golang.org>
Tue, 29 Oct 2013 15:50:18 +0000 (11:50 -0400)
committerRuss Cox <rsc@golang.org>
Tue, 29 Oct 2013 15:50:18 +0000 (11:50 -0400)
This code is only built when you run 'make' in cmd/gc,
not in all.bash.

R=golang-dev, jsing, iant
CC=golang-dev
https://golang.org/cl/19160043

src/cmd/gc/mkbuiltin1.c

index f8f61c278f695d7d6335f0083b387fc21d023fe9..69027fdf5d2ea55ec6b5e2ce2e1d787769537151 100644 (file)
@@ -62,7 +62,7 @@ begin:
                // sys.go claims to be in package PACKAGE to avoid
                // conflicts during "6g sys.go".  rename PACKAGE to $2.
                printf("\t\"");
-               while(q = strstr(p, "PACKAGE")) {
+               while((q = strstr(p, "PACKAGE")) != NULL) {
                        *q = 0;
                        esc(p); // up to the substitution
                        printf("%s", name);     // the sub name