Skip to content

Commit 01505de

Browse files
author
James E. Flemer
committed
(PHP opendir) Changed CHECKUID_ALLOW_ONLY_DIR to CHECKUID_ALLOW_ONLY_FILE
so that relative paths (vs absolute) work correctly.
1 parent 3dc95db commit 01505de

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ext/standard/dir.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ static void _php_do_opendir(INTERNAL_FUNCTION_PARAMETERS, int createobject)
151151
RETURN_FALSE;
152152
}
153153

154-
if (PG(safe_mode) &&(!php_checkuid(Z_STRVAL_PP(arg), NULL, CHECKUID_ALLOW_ONLY_DIR))) {
154+
if (PG(safe_mode) &&(!php_checkuid(Z_STRVAL_PP(arg), NULL, CHECKUID_ALLOW_ONLY_FILE))) {
155155
RETURN_FALSE;
156156
}
157157

0 commit comments

Comments
 (0)