summaryrefslogtreecommitdiff
path: root/ext/sockets/multicast.c
diff options
context:
space:
mode:
authorNikita Popov <nikita.ppv@gmail.com>2019-06-12 10:50:58 +0200
committerNikita Popov <nikita.ppv@gmail.com>2019-06-12 11:54:12 +0200
commitf601eb15e63590f00acd3453dbc24d4caaed1182 (patch)
treec33aa41158145b5d7691ec27c91470f93155bc58 /ext/sockets/multicast.c
parent06ddc025ac3ad09bdd344cb4779427c81dece9fd (diff)
downloadphp-git-f601eb15e63590f00acd3453dbc24d4caaed1182.tar.gz
Fix -Wmissing-braces warnings
Unfortunate that = {} is a GNU extension.
Diffstat (limited to 'ext/sockets/multicast.c')
-rw-r--r--ext/sockets/multicast.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/sockets/multicast.c b/ext/sockets/multicast.c
index af7165e8e0..2ede92bc6e 100644
--- a/ext/sockets/multicast.c
+++ b/ext/sockets/multicast.c
@@ -463,7 +463,7 @@ static int _php_mcast_join_leave(
sizeof(greq));
#else
if (sock->type == AF_INET) {
- struct ip_mreq mreq = {0};
+ struct ip_mreq mreq = {{0}};
struct in_addr addr;
assert(group_len == sizeof(struct sockaddr_in));
@@ -483,7 +483,7 @@ static int _php_mcast_join_leave(
}
#if HAVE_IPV6
else if (sock->type == AF_INET6) {
- struct ipv6_mreq mreq = {0};
+ struct ipv6_mreq mreq = {{0}};
assert(group_len == sizeof(struct sockaddr_in6));