mirror of
https://github.com/php/php-src.git
synced 2026-04-28 18:53:33 +02:00
- MFH: Fixed bug #27822 (is_resource() returns TRUE for closed resources)
This commit is contained in:
@@ -2,6 +2,7 @@ PHP 4 NEWS
|
||||
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||
?? ??? 2004, Version 4.3.6
|
||||
- Synchronized bundled GD library with GD 2.0.22. (Ilia)
|
||||
- Fixed bug #27822 (is_resource() returns TRUE for closed resources). (Derick)
|
||||
- Fixed bug #25547 (error_handler and array index with function call).
|
||||
(cschneid at cschneid dot com)
|
||||
- Fixed bug #27809 (ftp_systype returns null on some ftp servers). (Ilia)
|
||||
|
||||
@@ -208,6 +208,13 @@ static void php_is_type(INTERNAL_FUNCTION_PARAMETERS, int type)
|
||||
RETURN_FALSE;
|
||||
}
|
||||
}
|
||||
if (type == IS_RESOURCE) {
|
||||
char *type_name;
|
||||
type_name = zend_rsrc_list_get_rsrc_type(Z_LVAL_PP(arg) TSRMLS_CC);
|
||||
if (!type_name) {
|
||||
RETURN_FALSE;
|
||||
}
|
||||
}
|
||||
RETURN_TRUE;
|
||||
} else {
|
||||
RETURN_FALSE;
|
||||
|
||||
Reference in New Issue
Block a user