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

Potential memory leak when adding phrase to phrase book is aborted

    XMLWordPrintable

Details

    • 33a846a4d36ec339f8ddea08641ec02f2723a202 (qt/qttools/dev) ff81116cb967edc6707fe62217ad6a701d4d8d1f (qt/qttools/5.15)

    Description

      In mainwindow.cpp, MainWindow::adToPhraseBook, a new Phrase is allocated on the heap. If later on the QMessageBox::information("Add to phrase book", ...) confirmation is canceled, then 'phrase' is not added to the hash, and the pointer variable goes out of scope without being deleted.

      Coverity issue: https://scan3.coverity.com/reports.htm#v42553/p10113/fileInstanceId=32688635&defectInstanceId=8978285&mergedDefectId=22122

      Attachments

        Issue Links

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

          Activity

            People

              kkohne Kai Köhne
              vhilshei Volker Hilsheimer
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes