From 8aa2a9e0339215012354f3c4a262edda838134e8 Mon Sep 17 00:00:00 2001 From: "H.J. Lu" Date: Fri, 13 Dec 2024 05:38:57 +0800 Subject: Add braces in initializers for GCC 4.9 or older MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add braces to silence GCC 4.9 or older: getaddrinfo.c: In function ‘gaih_inet’: getaddrinfo.c:1135:24: error: missing braces around initializer [-Werror=missing-braces] / sizeof (struct gaih_typeproto)] = {0}; ^ Signed-off-by: H.J. Lu Reviewed-by: Sam James --- stdlib/tst-system.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'stdlib') diff --git a/stdlib/tst-system.c b/stdlib/tst-system.c index b5b630a41b..1878ee7ac2 100644 --- a/stdlib/tst-system.c +++ b/stdlib/tst-system.c @@ -80,7 +80,7 @@ sleep_and_check_sigchld (void *closure) sprintf (cmd, "sleep %lf" , *seconds); TEST_COMPARE (system (cmd), 0); - sigset_t blocked = {0}; + sigset_t blocked = {{0}}; TEST_COMPARE (sigprocmask (SIG_BLOCK, NULL, &blocked), 0); TEST_COMPARE (sigismember (&blocked, SIGCHLD), 0); return NULL; -- cgit v1.2.3