mirror of
https://github.com/php/php-src.git
synced 2025-08-19 08:49:28 +02:00
MFH: - Changed opendir/dir/scandir to use default context when no context argument is passed. (Sara)
This commit is contained in:
parent
d8edbd2729
commit
336cb15d69
2 changed files with 4 additions and 6 deletions
2
NEWS
2
NEWS
|
@ -1,6 +1,8 @@
|
|||
PHP NEWS
|
||||
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||
?? ??? 200?, PHP 5.3.0 Alpha 4
|
||||
- Changed opendir/dir/scandir to use default context
|
||||
when no context argument is passed. (Sara)
|
||||
|
||||
04 Dec 2008, PHP 5.3.0 Alpha 3
|
||||
- Upgraded bundled PCRE to version 7.8. (Nuno)
|
||||
|
|
|
@ -213,9 +213,7 @@ static void _php_do_opendir(INTERNAL_FUNCTION_PARAMETERS, int createobject)
|
|||
RETURN_NULL();
|
||||
}
|
||||
|
||||
if (zcontext) {
|
||||
context = php_stream_context_from_zval(zcontext, 0);
|
||||
}
|
||||
context = php_stream_context_from_zval(zcontext, 0);
|
||||
|
||||
dirp = php_stream_opendir(dirname, ENFORCE_SAFE_MODE|REPORT_ERRORS, context);
|
||||
|
||||
|
@ -558,9 +556,7 @@ PHP_FUNCTION(scandir)
|
|||
RETURN_FALSE;
|
||||
}
|
||||
|
||||
if (zcontext) {
|
||||
context = php_stream_context_from_zval(zcontext, 0);
|
||||
}
|
||||
context = php_stream_context_from_zval(zcontext, 0);
|
||||
|
||||
if (!flags) {
|
||||
n = php_stream_scandir(dirn, &namelist, context, (void *) php_stream_dirent_alphasort);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue