Subj : Re: kill executing script... To : Oystein Hallaraker From : Brendan Eich Date : Mon Jun 28 2004 05:17 pm Oystein Hallaraker wrote: > Hi! > Does anyone know how to kill an executing script before it is done? Do you mean stop execution from within a native function, getter/setter, etc.? Return false (after setting a pending exception or reporting an error, if possible -- otherwise you are intentionally creating a silent stop condition). > (can I use JS_DestroyContext()...?) No, that will crash. > And is it possible to disable all scripts > from a domain while mozilla is running? I have been looking at the > nsScriptSecurityManager, but it dosn't seem to have functionality to > support this. You could easily extend the system to support such disabling based on domain. Are you looking to make something work on existing releases of Mozilla products, just by using JS? I don't know of a way to do that. This is really a news://news.mozilla.org/netscape.public.mozilla.dom question. /be .