One change in Firefox 4 is to by default stop Firefox displaying the warning message, but it can be turned back on by changing some preferences.
- Type about:config into the location bar and press enter
- Accept the warning message that appears, you will be taken to a list of preferences
- Locate the preference browser.tabs.warnOnClose, if its value is set to false, double-click on it to change its value to true
- Repeat this for these 2 preferences browser.warnOnQuit, browser.warnOnRestart
- Starting with beta 12 there will be an additional preference that needs to be set to true - browser.showQuitWarning
source : http://support.mozilla.com/en-US/questions/786128