Closed Bug 787236 Opened 12 years ago Closed 12 years ago

Error when removing Reader:FaviconReturn observer on Reader uninit()

Categories

(Firefox for Android Graveyard :: Reader View, defect, P1)

All
Android
defect

Tracking

(firefox16 verified, firefox17 verified, firefox18 verified)

VERIFIED FIXED
Firefox 18
Tracking Status
firefox16 --- verified
firefox17 --- verified
firefox18 --- verified

People

(Reporter: lucasr, Assigned: lucasr)

Details

Attachments

(2 files)

We call bind() in the listener function which means the actual listener is not the named function. This patch fixes this.
Attachment #657061 - Flags: review?(mark.finkle)
Priority: -- → P1
Comment on attachment 657061 [details] [diff] [review]
Correctly remove "pagehide" listener when exiting Reader

Does this mean this ocde is wrong too?
http://mxr.mozilla.org/mozilla-central/source/mobile/android/chrome/content/browser.js#2684
Attachment #657061 - Flags: review?(mark.finkle) → review+
(In reply to Mark Finkle (:mfinkle) from comment #1)
> Comment on attachment 657061 [details] [diff] [review]
> Correctly remove "pagehide" listener when exiting Reader
> 
> Does this mean this ocde is wrong too?
> http://mxr.mozilla.org/mozilla-central/source/mobile/android/chrome/content/
> browser.js#2684

Yep, this is broken, the listener is never removed.
(In reply to Mark Finkle (:mfinkle) from comment #2)
> I assume this code is not affected becuase there is no "bind" ?
> http://mxr.mozilla.org/mozilla-central/source/browser/base/content/browser.
> js#4492

Correct.
Attachment #657245 - Flags: review?(mark.finkle) → review+
https://hg.mozilla.org/mozilla-central/rev/49ad41173c4f
https://hg.mozilla.org/mozilla-central/rev/5489c99c67d6
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 18
Comment on attachment 657061 [details] [diff] [review]
Correctly remove "pagehide" listener when exiting Reader

[Approval Request Comment]
Bug caused by (feature/regressing bug #): Small regression from bug 778582.
User impact if declined: Tons of errors in logcat and potential instability due to dangling listeners.
Testing completed (on m-c, etc.): Landed in Nightly, no issues found.
Risk to taking this patch (and alternatives if risky): Low, trivial patch.
String or UUID changes made by this patch: None
Attachment #657061 - Flags: approval-mozilla-beta?
Attachment #657061 - Flags: approval-mozilla-aurora?
Comment on attachment 657245 [details] [diff] [review]
Correctly remove "pagehide" listener for ErrorPageEventHandler

[Approval Request Comment]
User impact if declined: Dangling listeners and potential instability caused by dangling listeners on error pages (e.g. about:certerror)
Testing completed (on m-c, etc.): Landed in Nightly, no issues found.
Risk to taking this patch (and alternatives if risky): Low, trivial patch.
String or UUID changes made by this patch: None
Attachment #657245 - Flags: approval-mozilla-beta?
Attachment #657245 - Flags: approval-mozilla-aurora?
Comment on attachment 657061 [details] [diff] [review]
Correctly remove "pagehide" listener when exiting Reader

[Triage Comment]
Low risk fix in support of Reader Mode stability. While I don't believe we know what the user impact would really be if declined, we'll approve since we think we can manage the risk at this point.
Attachment #657061 - Flags: approval-mozilla-beta?
Attachment #657061 - Flags: approval-mozilla-beta+
Attachment #657061 - Flags: approval-mozilla-aurora?
Attachment #657061 - Flags: approval-mozilla-aurora+
Attachment #657245 - Flags: approval-mozilla-beta?
Attachment #657245 - Flags: approval-mozilla-beta+
Attachment #657245 - Flags: approval-mozilla-aurora?
Attachment #657245 - Flags: approval-mozilla-aurora+
Code changes were applied on the latest Nightly, Aurora and Beta builds. Closing bug as verified fixed.

--
Device: Galaxy Note
OS: Android 4.0.4
Status: RESOLVED → VERIFIED
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: