Closed Bug 334846 Opened 18 years ago Closed 18 years ago

[FIX]Assertion after EnableGlobalHistory

Categories

(Core Graveyard :: Embedding: GRE Core, defect, P3)

Tracking

(Not tracked)

RESOLVED FIXED
mozilla1.9alpha1

People

(Reporter: mikhail.zabaluev, Assigned: bzbarsky)

Details

(Keywords: assertion)

Attachments

(1 file, 1 obsolete file)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; ru; rv:1.8.0.2) Gecko/20060308 Firefox/1.5.0.2
Build Identifier: 

I embed the Gecko engine built from Xulrunner trunk. On creation of a browser window, it fails an assertion in nsWebBrowser::Create after EnableGlobalHistory has failed. Continued execution after the assertion exhibits no problems, and my embedding application doesn't even intend to use history. I opt to disable it both via nsIWebBrowserSetup and the flag to nsIWebNavigation::LoadURI.

Reproducible: Always




Xulrunner built from trunk as of 2006-04-18.
Attached patch This should fix it (obsolete) — Splinter Review
Benjamin, does this need sr?
Assignee: nobody → bzbarsky
Status: UNCONFIRMED → ASSIGNED
Attachment #219199 - Flags: review?(benjamin)
OS: Windows XP → All
Priority: -- → P3
Hardware: PC → All
Summary: Assertion after EnableGlobalHistory → [FIX]Assertion after EnableGlobalHistory
Target Milestone: --- → mozilla1.9alpha
Attachment #219199 - Flags: review?(benjamin) → review+
Attachment #219199 - Flags: superreview?(darin)
The patch solves my problem, thank you.
Comment on attachment 219199 [details] [diff] [review]
This should fix it

Hmm... it might be nice to set mHistoryEnabled inside EnableGlobalHistory.  That way, mHistoryEnabled does not get out-of-sync if someone happens to call EnableGlobalHistory without manually updating mHistoryEnabled.

Also, does it make sense to set mHistoryEnabled to true if EnableGlobalHistory fails?

sr=darin
Attachment #219199 - Flags: superreview?(darin) → superreview+
mHistoryEnabled is just an indicator of what the setup boolean is.  I could rename it to mShouldSetUpHistoryOnCreate if that would help...

> Also, does it make sense to set mHistoryEnabled to true if EnableGlobalHistory
> fails?

Yes, since it doesn't indicate whether history is actually enabled but whether we _should_ enable it on create.
Attachment #219199 - Attachment is obsolete: true
Fixed.
Status: ASSIGNED → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: