Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions ext/tidy/tidy.c
Original file line number Diff line number Diff line change
Expand Up @@ -737,7 +737,7 @@ static bool php_tidy_set_tidy_opt(TidyDoc doc, const char *optname, zval *value,
const zend_string *str = zval_get_tmp_string(value, &tmp_str);
const bool result = tidyOptSetValue(doc, tidyOptGetId(opt), ZSTR_VAL(str));
if (UNEXPECTED(!result)) {
zend_argument_type_error(arg, "option \"%s\" does not accept \"%s\" as a value", optname, ZSTR_VAL(str));
zend_argument_type_error(arg, "option \"%s\" does not accept \"%pS\" as a value", optname, str);
}
zend_tmp_string_release(tmp_str);
return result;
Expand All @@ -761,7 +761,7 @@ static bool php_tidy_set_tidy_opt(TidyDoc doc, const char *optname, zval *value,
} else {
result = tidyOptSetValue(doc, tidyOptGetId(opt), ZSTR_VAL(str));
if (UNEXPECTED(!result)) {
zend_argument_type_error(arg, "option \"%s\" does not accept \"%s\" as a value", optname, ZSTR_VAL(str));
zend_argument_type_error(arg, "option \"%s\" does not accept \"%pS\" as a value", optname, str);
}
}
zend_tmp_string_release(tmp_str);
Expand Down Expand Up @@ -1074,7 +1074,7 @@ PHP_FUNCTION(tidy_parse_file)
ZEND_PARSE_PARAMETERS_END();

if (!(contents = php_tidy_file_to_mem(inputfile, use_include_path))) {
php_error_docref(NULL, E_WARNING, "Cannot load \"%s\" into memory%s", ZSTR_VAL(inputfile), (use_include_path) ? " (using include path)" : "");
php_error_docref(NULL, E_WARNING, "Cannot load \"%pS\" into memory%s", inputfile, (use_include_path) ? " (using include path)" : "");
RETURN_FALSE;
}

Expand Down Expand Up @@ -1354,7 +1354,7 @@ PHP_METHOD(tidy, __construct)

if (inputfile) {
if (!(contents = php_tidy_file_to_mem(inputfile, use_include_path))) {
zend_throw_error(zend_ce_exception, "Cannot load \"%s\" into memory%s", ZSTR_VAL(inputfile), (use_include_path) ? " (using include path)" : "");
zend_throw_error(zend_ce_exception, "Cannot load \"%pS\" into memory%s", inputfile, (use_include_path) ? " (using include path)" : "");
RETURN_THROWS();
}

Expand Down Expand Up @@ -1399,7 +1399,7 @@ PHP_METHOD(tidy, parseFile)
obj = Z_TIDY_P(ZEND_THIS);

if (!(contents = php_tidy_file_to_mem(inputfile, use_include_path))) {
php_error_docref(NULL, E_WARNING, "Cannot load \"%s\" into memory%s", ZSTR_VAL(inputfile), (use_include_path) ? " (using include path)" : "");
php_error_docref(NULL, E_WARNING, "Cannot load \"%pS\" into memory%s", inputfile, (use_include_path) ? " (using include path)" : "");
RETURN_FALSE;
}

Expand Down
Loading