7

Please pardon my ignorance, relatively new to working with XULRunner.

I'm attempting to debug an issue with a XULRunner application and have hit a wall. We're using the app to load certain websites and retrieve layout information. After the scrape is done, we close the tab that the page has been loaded in. Occasionally, the number of tabs will grow continuously until memory is exhausted. Our theory is that the browser is hitting an unresponsive script which blocks execution indefinitely.

Is there a preference that can be set or something that will automatically kill tabs that hit an unresponsive script?

I've Googled around and the only thing I can find is

dom.max_script_run_time

which only allows you to specify how long to wait before popping up the "Unresponsive Script" dialog, but doesn't actually kill the tab.

Brian Webster
  • 30,033
  • 48
  • 152
  • 225
  • "Our theory is that the browser is hitting an unresponsive script" - did you confirm that theory? I mean, did you actually see the "unresponsive script" warning show up? There is a number of ways for a tab to exhaust memory... As to your question: no, there is no such setting. Which doesn't mean that the problem cannot be solved - but first you have to know what the problem is. – Wladimir Palant Oct 11 '12 at 20:38

1 Answers1

0

I'm not totally sure I understand, but here are my thoughts: You could run the script in a separate process, and then kill that process if it takes too long. Or you could have the script continuously check out long it's been running and then kill itself if it takes too long. Other than that I don't know what you could do.

sjelin
  • 303
  • 2
  • 7