Comment 6 for bug 73536

Revision history for this message
In , Mozilla (mozilla) wrote :

FWIW: That's the same on Linux.
People are closing their session often w/o closing every single application.

(In reply to comment #1)
> I don't know a lot about unix signal handling, but don't unix signals need to
> be handled synchronously? Or can we watch for SIGTERM, call
> nsIAppStartup.quit(), and return from the signal handler immediately, allowing
> the eventloop and stack to unwind gracefully later?

You can watch for SIGTERM since that signal should do the same as a normal exit. So you can catch the signal, start the shutdown process and return from the signal handler.

> Should SIGTERM cause eAttemptQuit (prompting the user if there is unsaved
> work/multiple tabs), or eForceQuit?

That's a harder question and I think there is no rule for that. I tend to vote for eForceQuit since if the application gets a SIGTERM the user may not be in front of the application (or display) at all.