File tree 2 files changed +16
-0
lines changed 2 files changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -2953,8 +2953,17 @@ static void clean_module_classes(int module_number) /* {{{ */
2953
2953
2954
2954
void module_destructor (zend_module_entry * module ) /* {{{ */
2955
2955
{
2956
+ #if ZEND_RC_DEBUG
2957
+ bool orig_rc_debug = zend_rc_debug ;
2958
+ #endif
2956
2959
2957
2960
if (module -> type == MODULE_TEMPORARY ) {
2961
+ #if ZEND_RC_DEBUG
2962
+ /* FIXME: Loading extensions during the request breaks some invariants.
2963
+ * In particular, it will create persistent interned strings, which is
2964
+ * not allowed at this stage. */
2965
+ zend_rc_debug = false;
2966
+ #endif
2958
2967
zend_clean_module_rsrc_dtors (module -> module_number );
2959
2968
clean_module_constants (module -> module_number );
2960
2969
clean_module_classes (module -> module_number );
@@ -2996,6 +3005,10 @@ void module_destructor(zend_module_entry *module) /* {{{ */
2996
3005
DL_UNLOAD (module -> handle );
2997
3006
}
2998
3007
#endif
3008
+
3009
+ #if ZEND_RC_DEBUG
3010
+ zend_rc_debug = orig_rc_debug ;
3011
+ #endif
2999
3012
}
3000
3013
/* }}} */
3001
3014
Original file line number Diff line number Diff line change @@ -60,6 +60,9 @@ PHPAPI PHP_FUNCTION(dl)
60
60
61
61
#if ZEND_RC_DEBUG
62
62
bool orig_rc_debug = zend_rc_debug ;
63
+ /* FIXME: Loading extensions during the request breaks some invariants. In
64
+ * particular, it will create persistent interned strings, which is not
65
+ * allowed at this stage. */
63
66
zend_rc_debug = false;
64
67
#endif
65
68
You can’t perform that action at this time.
0 commit comments