Closed
Bug 515463
Opened 15 years ago
Closed 15 years ago
new async autocomplete does not always respect behavior pref changes
Categories
(Firefox :: Address Bar, defect, P2)
Firefox
Address Bar
Tracking
()
VERIFIED
FIXED
Firefox 3.7a1
Tracking | Status | |
---|---|---|
status1.9.2 | --- | beta1-fixed |
People
(Reporter: mak, Assigned: sdwilsh)
References
Details
(Keywords: privacy, regression)
Attachments
(1 file, 1 obsolete file)
2.43 KB,
patch
|
mak
:
review+
|
Details | Diff | Splinter Review |
If you look at mixed (history and bookmarks) results and you flip the UI pref through values values, you can end up viewing bookmarks when history is selected, or viceversa (i've also seen results with Nothing selected)
Flags: blocking-firefox3.6?
Comment 1•15 years ago
|
||
Was working in Firefox 3.5.. might be related to the rewrite. I do see that we register a "" pref observer and reload all the prefs.
Keywords: regression
Reporter | ||
Updated•15 years ago
|
Assignee | ||
Comment 2•15 years ago
|
||
We only register for "browser.urlbar." changes.
Comment 3•15 years ago
|
||
blocking for broken UI and potential privacy exposure.
Flags: blocking-firefox3.6? → blocking-firefox3.6+
Comment 4•15 years ago
|
||
Not healthy to have blockers assigned to nobody@ - shawn, mardak, who's taking this?
Comment 5•15 years ago
|
||
assigning to shawn since it sounds like an asyncbar regression. reassign as needed.
Assignee: nobody → sdwilsh
Assignee | ||
Updated•15 years ago
|
Status: NEW → ASSIGNED
Whiteboard: [needs patch]
Assignee | ||
Updated•15 years ago
|
Priority: -- → P2
Assignee | ||
Comment 6•15 years ago
|
||
Can somebody give me more specific steps to reproduce? I thought I understood this bug, but it appears that I do not!
Reporter | ||
Comment 7•15 years ago
|
||
1. create a new profile 2. search for "moz" in the locationbar, you get results 3. change options -> privacy -> locationbar to "nothing" 4. search for "moz" in the locationbar, you don't get results 5. change options -> privacy -> locationbar to anything other than "nothing" 6. search for "moz" in the locationbar, you don't get results! iirc i was able to reproduce even in opposite directions, so not willing to see results i was seeing them. For example actually i have the pref set to "bookmarks" but i only see history results... restarting browser fixes the issue.
Assignee | ||
Comment 8•15 years ago
|
||
Silly me (and reviewers!). We don't hold onto our preference branch, so our observer can disappear. D'oh! Patch RSN!
Assignee | ||
Comment 9•15 years ago
|
||
Attachment #403346 -
Flags: review?(mak77)
Assignee | ||
Updated•15 years ago
|
Whiteboard: [needs patch] → [needs review mak]
Comment 10•15 years ago
|
||
Comment on attachment 403346 [details] [diff] [review] v1.0 >+ let pb = this._prefs.QueryInterface(Ci.nsIPrefBranch2); > pb.addObserver("", this, false); Why do we need to hold a reference to the prefs branch? Is that just so that there's a cycle between autocomplete and prefs and the GC doesn't collect it? I'm still not sure what's being collected to begin with.. Also, isn't that last argument "false" supposed to keep a strong reference -- not that autocomplete is getting collected in the first place.. ?
Assignee | ||
Comment 11•15 years ago
|
||
(In reply to comment #10) > Why do we need to hold a reference to the prefs branch? Is that just so that > there's a cycle between autocomplete and prefs and the GC doesn't collect it? > I'm still not sure what's being collected to begin with.. Pretty much. The preference branch will get a refcount of zero, and it will be deleted, taking our observer with it.
Assignee | ||
Comment 12•15 years ago
|
||
per comments on irc
Attachment #403346 -
Attachment is obsolete: true
Attachment #403351 -
Flags: review?(mak77)
Attachment #403346 -
Flags: review?(mak77)
Comment 13•15 years ago
|
||
Ah, that makes much more sense. I was getting confused trying to figure out how the pref service was going away, but it's just the particular branch we're requesting that disappears.
Reporter | ||
Comment 14•15 years ago
|
||
Comment on attachment 403351 [details] [diff] [review] v1.1 reviewed on IRC and manually tested working, r=me Still this gc thing is pretty strange looking, i would have expected that being the pref service still alive, branches derived from it were alive as well. I think could make sense to file a bug that blocks this and fuel issue about this thing, if no bug exists as of today. Could even be correct to avoid holding useless branches in memory but it's quite error-prone.
Attachment #403351 -
Flags: review?(mak77) → review+
Reporter | ||
Updated•15 years ago
|
Whiteboard: [needs review mak] → [has patch][can land]
Reporter | ||
Comment 15•15 years ago
|
||
i was thinking if flagging in-litmus is correct. the bug is reproduceable, but having a bug depending on gc on litmus could bring random results... maybe we should just flag it for generic: "set pref and check, unset pref and check"
Assignee | ||
Comment 16•15 years ago
|
||
(In reply to comment #15) > i was thinking if flagging in-litmus is correct. the bug is reproduceable, but > having a bug depending on gc on litmus could bring random results... maybe we > should just flag it for generic: "set pref and check, unset pref and check" Agreed. (In reply to comment #14) > Still this gc thing is pretty strange looking, i would have expected that being > the pref service still alive, branches derived from it were alive as well. > I think could make sense to file a bug that blocks this and fuel issue about > this thing, if no bug exists as of today. Could even be correct to avoid > holding useless branches in memory but it's quite error-prone. I recall discussions about this in the past saying that this is an invariant of the pref observer API.
Flags: in-testsuite-
Flags: in-litmus?
Whiteboard: [has patch][can land] → [can land]
Reporter | ||
Comment 17•15 years ago
|
||
http://hg.mozilla.org/mozilla-central/rev/62d4f947aab5
Status: ASSIGNED → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
Whiteboard: [can land]
Target Milestone: --- → Firefox 3.7a1
Reporter | ||
Comment 18•15 years ago
|
||
http://hg.mozilla.org/releases/mozilla-1.9.2/rev/66263046d823
status1.9.2:
--- → beta1-fixed
Comment 20•15 years ago
|
||
verified with: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.3a1pre) Gecko/20091111 Minefield/3.7a1pre
Status: RESOLVED → VERIFIED
You need to log in
before you can comment on or make changes to this bug.
Description
•