[Webkit-unassigned] [Bug 82764] New: [BlackBerry] PluginBlackBerry may leak strings

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Mar 30 11:50:41 PDT 2012


https://bugs.webkit.org/show_bug.cgi?id=82764

           Summary: [BlackBerry] PluginBlackBerry may leak strings
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: Unspecified
        OS/Version: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: Plug-ins
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: jmason at rim.com
                CC: atreat at rim.com


The BlackBerry::Platform::Window API has been updated to return std::string instead of char* from some methods.  When I updated webkit for this change, I noticed that PluginViewBlackBerry takes the returned strings and stuffs a pointer to them into an NPSetWindowCallbackStruct, where they are passed to the plugin.  It's not clear to me that the lifetime of the plugin is guaranteed to be tied to the window, and if the window is destroyed first this memory will become invalid.  So it's safer to also store a copy in the PluginBlackBerry object and put the pointer to that in the callback struct, so we can more carefully manage its lifetime.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list