[Webkit-unassigned] [Bug 75984] New: QWebView leaks memory when QObject signal is connected to javascript slot

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Jan 10 12:42:46 PST 2012


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

           Summary: QWebView leaks memory when QObject signal is connected
                    to javascript slot
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: PC
        OS/Version: Linux
            Status: UNCONFIRMED
          Severity: Normal
          Priority: P2
         Component: WebKit Qt
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: juha.kuikka at gmail.com


Created an attachment (id=121892)
 --> (https://bugs.webkit.org/attachment.cgi?id=121892&action=review)
Application that shows the problem

Versions:
QT 4.8 (./configure -prefix /opt/qt-x86-x11-4.8.0 -debug -qvfb -nomake demos -nomake examples)
Gcc (Ubuntu/Linaro 4.6.1-9ubuntu3) 4.6.1
Webkit version unknown (src/3rdparty/webkit/VERSION refers to 52a11cec052aa40d3bbc06861be1177b649b4a99)

Attached is an application and two web pages. Bug.html shows the issue, nobug.html does not. The presence of the jquery makes no difference but the more javascript content the web page has the more memory is leaked.

I see application leaking memory when javascript function is connected to a QObject signal (bug.html). When the connection is not made (nobug.html) the memory is not leaked.

In the attached example application (simplest browser) a QObject (Api) is exposed to the javascript layer through frame->addToJavaScriptWindowObject().

Javascipt then connects to "thing_happened" signal of said QObject with "Api.thing_happened.connect(callback_function)".

The web page (bug.html) contains a link to itself. While clicking this link the application leaks memory image on every click. According to valgrind the memory is not _leaked_ per se, it is apparently still reachable.

-- 
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