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

Initialize all TreeNode members in qpathclipper.cpp, SegmentTree::buildTree

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P3: Somewhat important
    • 5.15.1
    • 5.15
    • GUI: Painting
    • b7b17e719ea57f2d697bc0f61bffaa0fab910701 (qt/qtbase/dev) 1356f0c2c3c29cb5a5a676de23f3d582c140bc8c (qt/qtbase/5.15)

    Description

      Coverity reports in CID 218601 that TreeNode::splitLeft is uninitialized in TreeNodes where the TreeNode::leaf member is set to true.

      This is intentional; the splitLeft/Right data members are only ever used when the TreeNode is not a leaf. However, passing around uninitialized data members easily results in undefined behavior and hides bugs.

      Attachments

        Issue Links

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

          Activity

            People

              vhilshei Volker Hilsheimer
              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