Fix issue of losing tab state

Browser makes a backup of tab state when adding visited history and
page finished. When browser is being destroyed at times there could
be an instance where a background load triggers to write state while
the browser is already in cleanup state. This causes to write empty
state that looses the previous saved status .

Change-Id: I760c36e376c816302f8635c8e73d8b3871faf0b4
2 files changed