Skip to content

Commit 850a5a4

Browse files
committed
Merge branch 'PHP-8.4'
* PHP-8.4: Fix GH-16199: GREP_HEADER() is broken
2 parents d7f09eb + e915ed7 commit 850a5a4

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

win32/build/confutils.js

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -965,14 +965,19 @@ function GREP_HEADER(header_name, regex, path_to_check)
965965

966966
if (!c) {
967967
/* look in the include path */
968+
if (path_to_check == null) {
969+
path_to_check = php_usual_include_suspects;
970+
} else {
971+
path_to_check += ";" + php_usual_include_suspects;
972+
}
968973

969974
var p = search_paths(header_name, path_to_check, "INCLUDE");
970975
if (typeof(p) == "string") {
971-
c = file_get_contents(p);
976+
c = file_get_contents(p + "\\" + header_name);
972977
} else if (p == false) {
973978
p = search_paths(header_name, PHP_EXTRA_INCLUDES, null);
974979
if (typeof(p) == "string") {
975-
c = file_get_contents(p);
980+
c = file_get_contents(p + "\\" + header_name);
976981
}
977982
}
978983
if (!c) {

0 commit comments

Comments
 (0)