* tests/test-unsetenv.c (main): Make entry static. Even with this
change, it’s unclear whether this test is portable POSIX code, but
that’s a different matter.
2023-04-24 Paul Eggert <eggert@cs.ucla.edu>
+ unsetenv-tests: pacify -Wanalyzer-putenv-of-auto-var
+ * tests/test-unsetenv.c (main): Make entry static. Even with this
+ change, it’s unclear whether this test is portable POSIX code, but
+ that’s a different matter.
+
tests: suppress some unwanted -fanalyzer checking
* tests/test-dup2.c, tests/test-fcntl.c, tests/test-fopen.h:
* tests/test-getdtablesize.c, tests/test-listen.c:
int
main (void)
{
- char entry[] = "b=2";
+ /* Static to pacify gcc -Wanalyzer-putenv-of-auto-var. */
+ static char entry[] = "b=2";
/* Test removal when multiple entries present. */
ASSERT (putenv ((char *) "a=1") == 0);