mirror of
https://github.com/php/php-src.git
synced 2025-08-16 14:08:47 +02:00
Merge branch 'PHP-7.4'
This commit is contained in:
commit
3820296c42
1 changed files with 13 additions and 13 deletions
|
@ -677,19 +677,6 @@ int php_zip_pcre(zend_string *regexp, char *path, int path_len, zval *return_val
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
snprintf(fullpath, MAXPATHLEN, "%s%c%s", path, DEFAULT_SLASH, ZSTR_VAL(namelist[i]));
|
|
||||||
|
|
||||||
if (0 != VCWD_STAT(fullpath, &s)) {
|
|
||||||
php_error_docref(NULL, E_WARNING, "Cannot read <%s>", fullpath);
|
|
||||||
zend_string_release_ex(namelist[i], 0);
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (S_IFDIR == (s.st_mode & S_IFMT)) {
|
|
||||||
zend_string_release_ex(namelist[i], 0);
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
match_data = php_pcre_create_match_data(capture_count, re);
|
match_data = php_pcre_create_match_data(capture_count, re);
|
||||||
if (!match_data) {
|
if (!match_data) {
|
||||||
/* Allocation failed, but can proceed to the next pattern. */
|
/* Allocation failed, but can proceed to the next pattern. */
|
||||||
|
@ -704,6 +691,19 @@ int php_zip_pcre(zend_string *regexp, char *path, int path_len, zval *return_val
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
snprintf(fullpath, MAXPATHLEN, "%s%c%s", path, DEFAULT_SLASH, ZSTR_VAL(namelist[i]));
|
||||||
|
|
||||||
|
if (0 != VCWD_STAT(fullpath, &s)) {
|
||||||
|
php_error_docref(NULL, E_WARNING, "Cannot read <%s>", fullpath);
|
||||||
|
zend_string_release_ex(namelist[i], 0);
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (S_IFDIR == (s.st_mode & S_IFMT)) {
|
||||||
|
zend_string_release_ex(namelist[i], 0);
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
add_next_index_string(return_value, fullpath);
|
add_next_index_string(return_value, fullpath);
|
||||||
zend_string_release_ex(namelist[i], 0);
|
zend_string_release_ex(namelist[i], 0);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue