Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-29390

Memory leak warning when using QWebView::setUrl() in debug builds

    XMLWordPrintable

Details

    • Bug
    • Resolution: Invalid
    • P2: Important
    • None
    • 5.0.0, 5.0.1
    • WebKit
    • None
    • Windows 7 32-bit, Windows 7 64-bit

    Description

      Say your application has a QWebView widget. Now, if you run your application and do nothing with your QWebView widget, then there won't be any memory leak (as expected!). However, if you use the setUrl() method to open a web page, then upon leaving your application, you will see some memory leaks in the Application Output window (when running from Qt Creator; in fact, you will also get a couple of QFont-related issues):

      QFont::setPixelSize: Pixel size <= 0 (0)
      QFont::setPixelSize: Pixel size <= 0 (0)
      LEAK: 3 XMLHttpRequest
      LEAK: 28 CachedResource
      LEAK: 1302 WebCoreNode

      Attached is some sample code that illustrates the issue. If you start the application and close it within 3 seconds, then setUrl() won't be called and no memory leak will be reported. If you wait more than 3 seconds, setUrl() will be called and then, upon leaving the application, you will see something similar to the above output.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            shkearns Shane Kearns
            agarny Alan Garny
            Votes:
            8 Vote for this issue
            Watchers:
            16 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes