Skip to content

Commit 83b4e5a

Browse files
committed
Fixed issue #2372: PHP 8.5: Changes to glob interface
1 parent b635abf commit 83b4e5a

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

src/lib/maps/maps.c

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,10 @@
1616
#include <stddef.h>
1717
#include <stdlib.h>
1818

19+
#ifndef XDEBUG_NO_PHP_FEATURES
20+
# include "php_xdebug.h"
21+
#endif
22+
1923
#if PHP_VERSION_ID >= 80500
2024
# include "php_glob.h"
2125
# define xdebug_glob php_glob
@@ -33,7 +37,9 @@
3337
# define xdebug_globfree globfree
3438
#endif
3539

36-
#include "php_xdebug.h"
40+
#ifndef PHP_GLOB_NOMATCH
41+
# define PHP_GLOB_NOMATCH GLOB_NOMATCH
42+
#endif
3743

3844
#include "maps_private.h"
3945
#include "parser.h"
@@ -85,7 +91,7 @@ static void scan_directory(const char *dir)
8591
case 0: /* No error */
8692
break;
8793

88-
case GLOB_NOMATCH:
94+
case PHP_GLOB_NOMATCH:
8995
xdebug_log_ex(XLOG_CHAN_PATHMAP, XLOG_DEBUG, "NOMATCH", "No map files found with pattern '%s'", scan_dir);
9096
xdfree(scan_dir);
9197

0 commit comments

Comments
 (0)