Skip to content

Commit

Permalink
fix crash when entering rest at the end of the score
Browse files Browse the repository at this point in the history
  • Loading branch information
lasconic committed Jul 20, 2012
1 parent 8bb49e1 commit ccb12bc
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions libmscore/edit.cpp
Expand Up @@ -1455,12 +1455,8 @@ void Score::cmdEnterRest(const TDuration& d)

int track = _is.track();
NoteVal nval;
Segment* seg = setNoteRest(_is.segment(), track, nval, d.fraction(), AUTO);
if (seg) {
ChordRest* cr = static_cast<ChordRest*>(seg->element(track));
if (cr)
nextInputPos(cr, false);
}
setNoteRest(_is.segment(), track, nval, d.fraction(), AUTO);
moveToNextInputPos();
_is.rest = false; // continue with normal note entry
endCmd();
}
Expand Down

0 comments on commit ccb12bc

Please sign in to comment.