tony2001                Wed May 24 21:22:27 2006 UTC

  Modified files:              
    /php-src/ext/tidy   php_tidy.h tidy.c 
  Log:
  MFB: fix #37418 (tidy module crashes CLI version of PHP)
  
  
http://cvs.php.net/viewcvs.cgi/php-src/ext/tidy/php_tidy.h?r1=1.28&r2=1.29&diff_format=u
Index: php-src/ext/tidy/php_tidy.h
diff -u php-src/ext/tidy/php_tidy.h:1.28 php-src/ext/tidy/php_tidy.h:1.29
--- php-src/ext/tidy/php_tidy.h:1.28    Thu Mar 23 14:22:40 2006
+++ php-src/ext/tidy/php_tidy.h Wed May 24 21:22:27 2006
@@ -16,7 +16,7 @@
   +----------------------------------------------------------------------+
 */
 
-/* $Id: php_tidy.h,v 1.28 2006/03/23 14:22:40 john Exp $ */
+/* $Id: php_tidy.h,v 1.29 2006/05/24 21:22:27 tony2001 Exp $ */
 
 #ifndef PHP_TIDY_H
 #define PHP_TIDY_H
@@ -40,6 +40,7 @@
 #define TIDY_ATTR_ME(name, param) TIDY_METHOD_MAP(name, tam_ ##name, param)
 
 PHP_MINIT_FUNCTION(tidy);
+PHP_MSHUTDOWN_FUNCTION(tidy);
 PHP_RINIT_FUNCTION(tidy);
 PHP_MINFO_FUNCTION(tidy);
 
http://cvs.php.net/viewcvs.cgi/php-src/ext/tidy/tidy.c?r1=1.85&r2=1.86&diff_format=u
Index: php-src/ext/tidy/tidy.c
diff -u php-src/ext/tidy/tidy.c:1.85 php-src/ext/tidy/tidy.c:1.86
--- php-src/ext/tidy/tidy.c:1.85        Sun May  7 18:11:40 2006
+++ php-src/ext/tidy/tidy.c     Wed May 24 21:22:27 2006
@@ -16,7 +16,7 @@
   +----------------------------------------------------------------------+
 */
 
-/* $Id: tidy.c,v 1.85 2006/05/07 18:11:40 nlopess Exp $ */
+/* $Id: tidy.c,v 1.86 2006/05/24 21:22:27 tony2001 Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -330,7 +330,7 @@
        "tidy",
        tidy_functions,
        PHP_MINIT(tidy),
-       NULL,
+       PHP_MSHUTDOWN(tidy),
        PHP_RINIT(tidy),
        NULL,
        PHP_MINFO(tidy),
@@ -993,12 +993,23 @@
        return SUCCESS;
 }
 
+PHP_MSHUTDOWN_FUNCTION(tidy)
+{
+#ifdef ZTS
+       ts_free_id(tidy_globals_id);
+#else
+       tidy_globals_dtor(&tidy_globals TSRMLS_CC);
+#endif
+       UNREGISTER_INI_ENTRIES();
+       return SUCCESS;
+}
+
 PHP_MINFO_FUNCTION(tidy)
 {
        php_info_print_table_start();
        php_info_print_table_header(2, "Tidy support", "enabled");
        php_info_print_table_row(2, "libTidy Release", (char 
*)tidyReleaseDate());
-       php_info_print_table_row(2, "Extension Version", 
PHP_TIDY_MODULE_VERSION " ($Id: tidy.c,v 1.85 2006/05/07 18:11:40 nlopess Exp 
$)");
+       php_info_print_table_row(2, "Extension Version", 
PHP_TIDY_MODULE_VERSION " ($Id: tidy.c,v 1.86 2006/05/24 21:22:27 tony2001 Exp 
$)");
        php_info_print_table_end();
 
        DISPLAY_INI_ENTRIES();

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to