Index: openacs-4/packages/xotcl-core/tcl/01-debug-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xotcl-core/tcl/01-debug-procs.tcl,v diff -u -r1.93.2.46 -r1.93.2.47 --- openacs-4/packages/xotcl-core/tcl/01-debug-procs.tcl 27 Jan 2022 10:27:12 -0000 1.93.2.46 +++ openacs-4/packages/xotcl-core/tcl/01-debug-procs.tcl 3 Feb 2022 19:51:25 -0000 1.93.2.47 @@ -567,6 +567,19 @@ # } { + # + # The following block is a safety measure: When there is no cleanup + # for ::xo::cc defined, the object will survive a request and many + # things might go wrong. The test is quite cheap an can reduce + # debugging time on some sites. + # + if {[info commands ::xo::cc] ne ""} { + if {![info exists ::xo::cleanup(::xo::cc)]} { + ns_log notice [::xo::cc serialize] + ns_log error "no cleanup for ::xo::cc registered" + ::xo::cc destroy + } + } ::xo::dc profile off ::xo::broadcast receive