summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulien Voisin2023-12-07 12:35:39 +0100
committerGitHub2023-12-07 12:35:39 +0100
commit4c37ccb166e1086193a868ce34131d455f002ba2 (patch)
tree1fe785f5234ef9d771454573817e34b6dc20b236
parent78ce29ef1a9ba8294e9187920c79fd8df5039547 (diff)
parent912080926895ba932a877a09c2e7d2592ce34f06 (diff)
make 'phar' filenames work in sp.disabled_functions
This fixes #472
-rw-r--r--src/sp_config_keywords.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/sp_config_keywords.c b/src/sp_config_keywords.c
index e7ff3e6..6733503 100644
--- a/src/sp_config_keywords.c
+++ b/src/sp_config_keywords.c
@@ -368,7 +368,7 @@ SP_PARSE_FN(parse_disabled_functions) {
368 goto out; 368 goto out;
369 } 369 }
370 if (df->filename && (*ZSTR_VAL(df->filename) != '/') && 370 if (df->filename && (*ZSTR_VAL(df->filename) != '/') &&
371 (0 != strncmp(ZSTR_VAL(df->filename), "phar://", sizeof("phar://")))) { 371 (0 != strncmp(ZSTR_VAL(df->filename), "phar://", strlen("phar://")))) {
372 sp_log_err("config", "Invalid configuration line: 'sp.disabled_functions': '.filename' must be an absolute path or a phar archive on line %zu", parsed_rule->lineno); 372 sp_log_err("config", "Invalid configuration line: 'sp.disabled_functions': '.filename' must be an absolute path or a phar archive on line %zu", parsed_rule->lineno);
373 goto out; 373 goto out;
374 } 374 }