Opened on 01/21/2015 at 07:18:24 AM
Closed on 01/21/2015 at 02:02:19 PM
#1840 closed defect (fixed)
"forward" messages cause memory leaks
Reported by: | sebastian | Assignee: | sebastian |
---|---|---|---|
Priority: | P2 | Milestone: | Adblock-Plus-1.8.11-for-Chrome-Opera-Safari |
Module: | Platform | Keywords: | |
Cc: | Blocked By: | ||
Blocking: | Platform: | Unknown | |
Ready: | yes | Confidential: | no |
Tester: | Verified working: | ||
Review URL(s): |
Description
Background
The "Block element" feaure requires to send messages between frames on a page. In order to do so the background page provides the forward message type, which sends the payload back to all frames of the page the message came from. For those messages the onMessage listener indicates to call sendResponse() asynchronously by returning true. However, most messages don't result into a response. Hence the port is kept open forever and the callback is leaked.
What to change
Add a flag to the forward message type indicating that a response is expected. If this flag isn't set, the response should be ignored and the onMessagehandler must not return true (indicating that a response will be send later).
Attachments (0)
Change History (3)
comment:1 Changed on 01/21/2015 at 07:19:23 AM by sebastian
- Review URL(s) modified (diff)
- Status changed from new to reviewing
comment:2 Changed on 01/21/2015 at 07:26:29 AM by sebastian
- Type changed from change to defect
comment:3 Changed on 01/21/2015 at 02:02:19 PM by sebastian
- Milestone set to Adblock-Plus-for-Chrome-Opera-Safari-next
- Resolution set to fixed
- Status changed from reviewing to closed
https://hg.adblockplus.org/adblockpluschrome/rev/2c9eb253a31d