diff --git a/src/nsqphp/Connection/Connection.php b/src/nsqphp/Connection/Connection.php index 6a49e6d..203d265 100644 --- a/src/nsqphp/Connection/Connection.php +++ b/src/nsqphp/Connection/Connection.php @@ -215,7 +215,7 @@ public function write($buf) public function getSocket() { if ($this->socket === NULL) { - $this->socket = fsockopen($this->hostname, $this->port, $errNo, $errStr, $this->connectionTimeout); + $this->socket = @fsockopen($this->hostname, $this->port, $errNo, $errStr, $this->connectionTimeout); if ($this->socket === FALSE) { throw new ConnectionException( "Could not connect to {$this->hostname}:{$this->port} ({$errStr} [{$errNo}])" @@ -242,4 +242,4 @@ public function __toString() { return "{$this->hostname}:{$this->port}"; } -} \ No newline at end of file +}