Nice explanations to the HTML5 Outlining Model, and how we should do it correctly.
defaults write com.apple.Safari NSQuitAlwaysKeepsWindows -bool true
The keep windows feature was introduced in OS X 10.7 Lion, but now it’s set false as default in OS X 10.9 Mavericks. And I think it’s good to drop windows when you quit an App in OS X, since the logic is different from iOS.
But sometimes if you want one or two specific App to keep windows (I want Terminal, for instance,) just override the preference settings with commands above.