We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 945e5d3 commit cdefeb7Copy full SHA for cdefeb7
ext/sockets/multicast.c
@@ -463,8 +463,9 @@ static int _php_mcast_join_leave(
463
sizeof(greq));
464
#else
465
if (sock->type == AF_INET) {
466
- struct ip_mreq mreq = {{0}};
+ struct ip_mreq mreq;
467
struct in_addr addr;
468
+ memset(&mreq, 0, sizeof(struct ip_mreq));
469
470
assert(group_len == sizeof(struct sockaddr_in));
471
@@ -483,7 +484,8 @@ static int _php_mcast_join_leave(
483
484
}
485
#if HAVE_IPV6
486
else if (sock->type == AF_INET6) {
- struct ipv6_mreq mreq = {{0}};
487
+ struct ipv6_mreq mreq;
488
+ memset(&mreq, 0, sizeof(struct ipv6_mreq));
489
490
assert(group_len == sizeof(struct sockaddr_in6));
491
0 commit comments