From: Ian Lance Taylor Date: Thu, 11 Mar 2021 23:09:47 +0000 (-0800) Subject: misc/cgo/testcarchive: don't use == for string equality in C code X-Git-Tag: go1.17beta1~1152 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=73eb27bd3b;p=gostls13.git misc/cgo/testcarchive: don't use == for string equality in C code For https://gcc.gnu.org/PR99553 Change-Id: I29a7fbfd89963d4139bc19af99330d70567938ea Reviewed-on: https://go-review.googlesource.com/c/go/+/300993 Trust: Ian Lance Taylor Run-TryBot: Ian Lance Taylor TryBot-Result: Go Bot Reviewed-by: Emmanuel Odeke --- diff --git a/misc/cgo/testcarchive/testdata/main_unix.c b/misc/cgo/testcarchive/testdata/main_unix.c index b23ac1c242..bd00f9d233 100644 --- a/misc/cgo/testcarchive/testdata/main_unix.c +++ b/misc/cgo/testcarchive/testdata/main_unix.c @@ -36,7 +36,7 @@ int install_handler() { return 2; } // gccgo does not set SA_ONSTACK for SIGSEGV. - if (getenv("GCCGO") == "" && (osa.sa_flags&SA_ONSTACK) == 0) { + if (getenv("GCCGO") == NULL && (osa.sa_flags&SA_ONSTACK) == 0) { fprintf(stderr, "Go runtime did not install signal handler\n"); return 2; }