Enable binding ports for IPv6
This commit is contained in:
@@ -49,7 +49,7 @@ final class SocketServer {
|
||||
if (! extension_loaded('pcntl'))
|
||||
throw new SocketException(SocketException::CANT_ACCEPT,'Missing pcntl extension');
|
||||
|
||||
$this->server = socket_create(AF_INET,SOCK_STREAM,SOL_TCP);
|
||||
$this->server = socket_create(AF_INET|AF_INET6,SOCK_STREAM,SOL_TCP);
|
||||
|
||||
if ($this->server === FALSE)
|
||||
throw new SocketException(SocketException::CANT_CREATE_SOCKET,socket_strerror(socket_last_error()));
|
||||
|
Reference in New Issue
Block a user