mirror of
https://github.com/php/php-src.git
synced 2024-12-01 13:54:10 +08:00
- MFH trailing slashes detection
This commit is contained in:
parent
0beae1e558
commit
12a3e339f4
@ -1955,7 +1955,7 @@ function PHP_INSTALL_HEADERS(dir, headers_list)
|
||||
{
|
||||
headers_list = headers_list.split(new RegExp("\\s+"));
|
||||
headers_list.sort();
|
||||
if (dir.length > 0 && dir.substr(dir.length - 1) != '/') {
|
||||
if (dir.length > 0 && dir.substr(dir.length - 1) != '/' && dir.substr(dir.length - 1) != '\\') {
|
||||
dir += '/';
|
||||
}
|
||||
dir = dir.replace(new RegExp("/", "g"), "\\");
|
||||
@ -1966,7 +1966,7 @@ function PHP_INSTALL_HEADERS(dir, headers_list)
|
||||
isdir = FSO.FolderExists(dir + src);
|
||||
isfile = FSO.FileExists(dir + src);
|
||||
if (isdir) {
|
||||
if (src.length > 0 && src.substr(src.length - 1) != '/') {
|
||||
if (src.length > 0 && src.substr(src.length - 1) != '/' && src.substr(src.length - 1) != '\\') {
|
||||
src += '\\';
|
||||
}
|
||||
headers_install[headers_install.length] = [dir + src, 'dir',''];
|
||||
|
Loading…
Reference in New Issue
Block a user