From: Antony Dovgal Date: Tue, 20 Apr 2010 10:04:26 +0000 (+0000) Subject: fix infinite loop in the test X-Git-Tag: php-5.3.3RC1~299 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9c97c268320c119e95344462af20c81185a4840c;p=php fix infinite loop in the test --- diff --git a/ext/openssl/tests/bug48182.phpt b/ext/openssl/tests/bug48182.phpt index 7471c4c5df..146c4c9226 100644 --- a/ext/openssl/tests/bug48182.phpt +++ b/ext/openssl/tests/bug48182.phpt @@ -51,7 +51,7 @@ function ssl_async_client($port) { $socket = stream_socket_client($host, $errno, $errstr, 10, $flags); stream_set_blocking($socket, 0); - while ($data) { + while ($socket && $data) { $wrote = fwrite($socket, $data, strlen($data)); $data = substr($data, $wrote); }