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

Memory leak in QClipboard::setMimeData() in Wayland

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P1: Critical
    • 6.5.2, 6.6.0
    • 5.15.9, 6.5.0
    • QPA: Wayland
    • None
    • Linux/Wayland

    Description

      Copy anything to a QClipboard using

      auto mimedata = new QMimeData();
      ...
      QGuiApplication::clipboard()->setMimeData(mimedata);

      Expected behavior:

      The clipboard takes ownership of the data as stated in the documentation.

      Actual behavior:

      A memory leak is detected. Apparently the clipboard did not take ownership.

       

      Only wayland appears to be affected, when using QPA_PLATFORM_PLUGIN=xcb I observe no memory leak.

      Attachments

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

        Activity

          People

            qt.team.graphics.and.multimedia Qt Graphics Team
            valentinb Valentin B
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes