tony2001                                 Tue, 20 Apr 2010 10:04:26 +0000

Revision: http://svn.php.net/viewvc?view=revision&revision=298200

Log:
fix infinite loop in the test

Changed paths:
    U   php/php-src/branches/PHP_5_3/ext/openssl/tests/bug48182.phpt
    U   php/php-src/trunk/ext/openssl/tests/bug48182.phpt

Modified: php/php-src/branches/PHP_5_3/ext/openssl/tests/bug48182.phpt
===================================================================
--- php/php-src/branches/PHP_5_3/ext/openssl/tests/bug48182.phpt        
2010-04-20 07:40:40 UTC (rev 298199)
+++ php/php-src/branches/PHP_5_3/ext/openssl/tests/bug48182.phpt        
2010-04-20 10:04:26 UTC (rev 298200)
@@ -51,7 +51,7 @@
        $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);
        }

Modified: php/php-src/trunk/ext/openssl/tests/bug48182.phpt
===================================================================
--- php/php-src/trunk/ext/openssl/tests/bug48182.phpt   2010-04-20 07:40:40 UTC 
(rev 298199)
+++ php/php-src/trunk/ext/openssl/tests/bug48182.phpt   2010-04-20 10:04:26 UTC 
(rev 298200)
@@ -51,7 +51,7 @@
        $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);
        }

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to