Skip to content

Commit

Permalink
Fix Element memory leak
Browse files Browse the repository at this point in the history
  • Loading branch information
trig-ger committed Sep 6, 2014
1 parent 6da8c08 commit 330e232
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
5 changes: 5 additions & 0 deletions mscore/palette.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,11 @@

namespace Ms {

PaletteCell::~PaletteCell()
{
delete element;
}

//---------------------------------------------------------
// needsStaff
// should a staff been drawn if e is used as icon in
Expand Down
2 changes: 2 additions & 0 deletions mscore/palette.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@ class Palette;
//---------------------------------------------------------

struct PaletteCell {
~PaletteCell();

Element* element { 0 };
QString name; // used for tool tip
QString tag;
Expand Down

0 comments on commit 330e232

Please sign in to comment.