Skip to content

Commit

Permalink
MythUI: Fix use after free in MythUIEditBar
Browse files Browse the repository at this point in the history
The call to ReleaseImages() in MythUIEditBar's dtor caused a free memory read
since SetRedraw() accesses its parent whose dtor has already been called.

Calling ReleaseImages() from MythUIEditBar's dtor also isn't necessary since the
images in m_images are children of MythUIEditBar and are automatically deleted
by Qt.

Fixes #11458, Refs #11402
  • Loading branch information
natanojl committed Mar 19, 2013
1 parent 5769dca commit 6e0f69d
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion mythtv/libs/libmythui/mythuieditbar.cpp
Expand Up @@ -8,7 +8,6 @@ MythUIEditBar::MythUIEditBar(MythUIType *parent, const QString &name)

MythUIEditBar::~MythUIEditBar(void)
{
ReleaseImages();
}

void MythUIEditBar::ReleaseImages(void)
Expand Down

0 comments on commit 6e0f69d

Please sign in to comment.