Hi guys, I am currently facing a problem that some UI chrome code implements a listener interface in JS and passes an object to the outer chrome world /XPCOM (components). If the chrome dialog is closed, its JS context is killed although those wrapped listeners are still exposed to the XPCOM world and may still be called! In that case JS execution runs into trouble, not even the global "Components" object is available. That case is asserted very well in debug builds:
<assertion> ###!!! ASSERTION: XPConnect is being called on a scope without a 'Components' pr operty! This is pretty much always bad. It usually means that native code is making a callback to an interface implemented in JavaScript, but the document where the JS object was created has already been cleared and the global properties of that document's window are *gone*. Generally this indicates a problem that should be addressed in the design and use of the callback code. : 'Error', file /mdev/mozilla/js/src/xpconnect/src/xpcwrappednativescope.cpp, line 564 </assertion> Now, how is this (IMO very common and thus well-asserted scenario) solved? Second, I am asking myself whether this makes sense. Why isn't the JS context held until the last proxy object has been released? thanks in advance, regards, -Daniel _______________________________________________ dev-tech-xpcom mailing list dev-tech-xpcom@lists.mozilla.org https://lists.mozilla.org/listinfo/dev-tech-xpcom