From: Antony Dovgal Date: Thu, 1 Dec 2005 14:02:54 +0000 (+0000) Subject: fix #35490 (socket_sendto() unable to handle IPv6 addresses) X-Git-Tag: php-5.1.2RC1~272 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=7a652e397b480c5683333a223c4342c23241c27c;p=php fix #35490 (socket_sendto() unable to handle IPv6 addresses) --- diff --git a/NEWS b/NEWS index 862b5117da..60a8752607 100644 --- a/NEWS +++ b/NEWS @@ -20,6 +20,7 @@ PHP NEWS connecting to 5.x server. (Andrey) - Fixed bug #35496 (Crash in mcrypt_generic()/mdecrypt_generic() without proper init). (Ilia) +- Fixed bug #35490 (socket_sendto() unable to handle IPv6 addresses). (Tony) - Fixed bug #35437 (Segfault or Invalid Opcode 137/1/4). (Dmitry) - Fixed bug #34729 (Crash in ZTS mode under Apache). (Dmitry, Zeev) - Fixed bug #35470 (Assigning global using variable name from array doesn't diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c index 1711a4e235..d57efa7d03 100644 --- a/ext/sockets/sockets.c +++ b/ext/sockets/sockets.c @@ -1482,7 +1482,7 @@ PHP_FUNCTION(socket_sendto) RETURN_FALSE; } - retval = sendto(php_sock->bsd_socket, buf, (len > buf_len) ? buf_len : len, flags, (struct sockaddr *) &sin, sizeof(sin)); + retval = sendto(php_sock->bsd_socket, buf, (len > buf_len) ? buf_len : len, flags, (struct sockaddr *) &sin6, sizeof(sin6)); break; #endif default: