Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

added the connection-timeout parameter to the stream_socket_client #12

Merged
merged 1 commit into from

2 participants

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
This page is out of date. Refresh to see the latest.
Showing with 2 additions and 2 deletions.
  1. +2 −2 PhpAmqpLib/Connection/AMQPConnection.php
View
4 PhpAmqpLib/Connection/AMQPConnection.php
@@ -67,12 +67,12 @@ public function __construct($host, $port,
if($context)
{
$remote = sprintf('ssl://%s:%s', $host, $port);
- $this->sock = stream_socket_client($remote, $errno, $errstr, 60, STREAM_CLIENT_CONNECT, $context);
+ $this->sock = stream_socket_client($remote, $errno, $errstr, $connection_timeout, STREAM_CLIENT_CONNECT, $context);
}
else
{
$remote = sprintf('tcp://%s:%s', $host, $port);
- $this->sock = stream_socket_client($remote, $errno, $errstr, 60, STREAM_CLIENT_CONNECT);
+ $this->sock = stream_socket_client($remote, $errno, $errstr, $connection_timeout, STREAM_CLIENT_CONNECT);
}
if (!$this->sock)
Something went wrong with that request. Please try again.