iliaa Sun Feb 3 16:14:17 2008 UTC
Modified files: (Branch: PHP_5_3)
/php-src/ext/standard streamsfuncs.c
Log:
Fixed bug #44028 (crash inside stream_socket_enable_crypto() when enabling
encryption without crypto type)
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/streamsfuncs.c?r1=1.58.2.6.2.15.2.8&r2=1.58.2.6.2.15.2.9&diff_format=u
Index: php-src/ext/standard/streamsfuncs.c
diff -u php-src/ext/standard/streamsfuncs.c:1.58.2.6.2.15.2.8
php-src/ext/standard/streamsfuncs.c:1.58.2.6.2.15.2.9
--- php-src/ext/standard/streamsfuncs.c:1.58.2.6.2.15.2.8 Mon Dec 31
07:17:15 2007
+++ php-src/ext/standard/streamsfuncs.c Sun Feb 3 16:14:16 2008
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: streamsfuncs.c,v 1.58.2.6.2.15.2.8 2007/12/31 07:17:15 sebastian Exp $
*/
+/* $Id: streamsfuncs.c,v 1.58.2.6.2.15.2.9 2008/02/03 16:14:16 iliaa Exp $ */
#include "php.h"
#include "php_globals.h"
@@ -1328,6 +1328,9 @@
if (php_stream_xport_crypto_setup(stream, cryptokind,
sessstream TSRMLS_CC) < 0) {
RETURN_FALSE;
}
+ } else if (enable) {
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "When enabling
encryption you must specify the crypto type");
+ RETURN_FALSE;
}
ret = php_stream_xport_crypto_enable(stream, enable TSRMLS_CC);
--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php