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

QTreeWidget drag crashes

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Not Evaluated
    • 4.8.x
    • 4.8.1
    • GUI: Drag and Drop
    • None
    • Windows 7 x64
    • ebaaff84fc0355d2e026da7f5ca015280b2c7d82 (4.8)

    Description

      Hiding an item in a QTreeWidget and then drag a remaining visible one could cause an 'index out of range' assert. I attached an example to demonstrate the problem. You can find the code fragment that causes the crash in qtreeview.cpp line 1381 - QTreeViewPrivate::adjustViewOptionsForIndex.

      The vector viewItems only contains one object - which i guess is correct, because the first item is hidden - and the model indexes row is 1 - which is also correct. But since the item is accessed with the row of the model index ((viewItems.at(row)), the program crashes.

      Attachments

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

        Activity

          People

            Unassigned Unassigned
            michaelernst Michael Ernst
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes