mirror of
https://github.com/php/php-src.git
synced 2024-09-24 03:17:26 +00:00
Fix errormessage check
# Is correct in 5.
This commit is contained in:
parent
b57c3201e0
commit
ba2182a44c
@ -515,7 +515,7 @@ PHP_FUNCTION(stream_wrapper_register)
|
||||
RETURN_TRUE;
|
||||
} else {
|
||||
/* We failed. But why? */
|
||||
if (zend_hash_exists(php_stream_get_url_stream_wrappers_hash(), protocol, protocol_len)) {
|
||||
if (zend_hash_exists(php_stream_get_url_stream_wrappers_hash(), protocol, protocol_len+1)) {
|
||||
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Protocol %s:// is already defined", protocol);
|
||||
} else {
|
||||
/* Hash doesn't exist so it must have been an invalid protocol scheme */
|
||||
|
Loading…
Reference in New Issue
Block a user