Does what it is supposed to be doing, under Linux at least. Rated 5 out of 5 stars

Another way to implement such a protection against the CTRL-Q shortcut feature is:
https://addons.mozilla.org/en-US/firefox/addon/always-ask/

Depending on the circumstances of your current browsing conditions, you might like one better than the other. Personally, having tried both, and in retrospective, I like this one better than "always ask," which, like the title says, always asks upon browser exiting, even through CTRL-W-ing, which may be obtrusive at times.

This review is for a previous version of the add-on (20110717).  This user has other reviews of this add-on.