fix #270433: Crash when pasting a note with an articulation if the final note is split between two measures

This commit is contained in:
Matt McClinch 2018-07-20 11:03:35 -04:00
parent 6a015b8e4e
commit db450fd34b
2 changed files with 5 additions and 2 deletions

View file

@ -2816,6 +2816,9 @@ void Chord::removeMarkings(bool keepTremolo)
if (arpeggio())
remove(arpeggio());
qDeleteAll(graceNotes());
graceNotes().clear();
qDeleteAll(articulations());
articulations().clear();
for (Note* n : notes()) {
for (Element* e : n->el())
n->remove(e);

View file

@ -1235,9 +1235,9 @@ int ChordRest::lastVerse(Placement p) const
void ChordRest::removeMarkings(bool /* keepTremolo */)
{
qDeleteAll(el());
if (isChord())
qDeleteAll(toChord(this)->articulations());
el().clear();
qDeleteAll(lyrics());
lyrics().clear();
}
//---------------------------------------------------------