fix infinite loop in the test

This commit is contained in:
Antony Dovgal 2010-04-20 10:04:26 +00:00
parent b47136d332
commit 9c97c26832

View File

@ -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);
}