diff options
| author | Christoph M. Becker <cmbecker69@gmx.de> | 2020-11-14 15:03:58 +0100 |
|---|---|---|
| committer | Christoph M. Becker <cmbecker69@gmx.de> | 2020-11-22 14:02:29 +0100 |
| commit | 221345a013cad854718b438c9dc869332853df63 (patch) | |
| tree | 84f1cddd1396a75d077457f0c2d3793214b06e99 /ext/tidy/tidy.c | |
| parent | ed949a197333ee0fef5a4f6b497e8e39158730c4 (diff) | |
| download | php-git-221345a013cad854718b438c9dc869332853df63.tar.gz | |
Fix #77594: ob_tidyhandler is never reset
We reset to original INI value on request shutdown.
Closes GH-6425.
Diffstat (limited to 'ext/tidy/tidy.c')
| -rw-r--r-- | ext/tidy/tidy.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/ext/tidy/tidy.c b/ext/tidy/tidy.c index a1a5184dd5..266e6510ef 100644 --- a/ext/tidy/tidy.c +++ b/ext/tidy/tidy.c @@ -240,6 +240,7 @@ static int php_tidy_output_handler(void **nothing, php_output_context *output_co static PHP_MINIT_FUNCTION(tidy); static PHP_MSHUTDOWN_FUNCTION(tidy); static PHP_RINIT_FUNCTION(tidy); +static PHP_RSHUTDOWN_FUNCTION(tidy); static PHP_MINFO_FUNCTION(tidy); static PHP_FUNCTION(tidy_getopt); @@ -500,7 +501,7 @@ zend_module_entry tidy_module_entry = { PHP_MINIT(tidy), PHP_MSHUTDOWN(tidy), PHP_RINIT(tidy), - NULL, + PHP_RSHUTDOWN(tidy), PHP_MINFO(tidy), PHP_TIDY_VERSION, PHP_MODULE_GLOBALS(tidy), @@ -1106,6 +1107,13 @@ static PHP_RINIT_FUNCTION(tidy) return SUCCESS; } +static PHP_RSHUTDOWN_FUNCTION(tidy) +{ + TG(clean_output) = INI_ORIG_BOOL("tidy.clean_output"); + + return SUCCESS; +} + static PHP_MSHUTDOWN_FUNCTION(tidy) { UNREGISTER_INI_ENTRIES(); |
