diff --git a/libmscore/repeatlist.cpp b/libmscore/repeatlist.cpp index 33872479e757..3c87d878bf0a 100644 --- a/libmscore/repeatlist.cpp +++ b/libmscore/repeatlist.cpp @@ -364,9 +364,9 @@ void RepeatList::unwind() Measure* nm = _score->searchLabel(s->jumpTo()); endRepeat = _score->searchLabel(s->playUntil()); continueAt = _score->searchLabel(s->continueAt()); - isGoto = true; if (nm && endRepeat) { + isGoto = true; rs->len = m->endTick() - rs->tick; append(rs); rs = new RepeatSegment; diff --git a/mtest/libmscore/repeat/repeat26.mscx b/mtest/libmscore/repeat/repeat26.mscx new file mode 100644 index 000000000000..8daf07bde326 --- /dev/null +++ b/mtest/libmscore/repeat/repeat26.mscx @@ -0,0 +1,226 @@ + + + + + 0 + 480 + + 1 + 1 + 1 + 0 + + Composer + + + + + + + + + Title + + + + + + + + + + + + + + stdNormal + + + Piano + + Piano + Pno. + Piano + 21 + 108 + 21 + 108 + F + + 100 + 95 + + + 100 + 33 + + + 100 + 50 + + + 100 + 67 + + + 100 + 100 + + + 120 + 67 + + + 120 + 100 + + + + + + + + + + 2 + + line + + + + Empty Jump + + + + + + 4 + 4 + 1 + + + start-repeat + 1 + + + 11223 + + + quarter + + 72 + 14 + + + + quarter + + 72 + 14 + + + + quarter + + 72 + 14 + + + + quarter + + 72 + 14 + + + + + + 2 + + line + + + + Garbage Jump + test + test + test + + + start-repeat + 1 + + + quarter + + 74 + 16 + + + + quarter + + 74 + 16 + + + + quarter + + 74 + 16 + + + + quarter + + 74 + 16 + + + + + + line + + + quarter + + 76 + 18 + + + + quarter + + + half + + + end + 1 + + + + + diff --git a/mtest/libmscore/repeat/tst_repeat.cpp b/mtest/libmscore/repeat/tst_repeat.cpp index 6b38e60a70f1..9e6a52fdbdc1 100644 --- a/mtest/libmscore/repeat/tst_repeat.cpp +++ b/mtest/libmscore/repeat/tst_repeat.cpp @@ -64,6 +64,9 @@ class TestRepeat : public QObject, public MTest void repeat24() { repeat("repeat24.mscx", "1;2;3;4;2;3;4;5;3;4;5;6"); } // imbricated DS and ||: :|| void repeat25() { repeat("repeat25.mscx", "1;2;1;2;3;4;2;3;4;5;4;5"); } // imbricated DS and ||: :|| + + void repeat26() { repeat("repeat26.mscx", "1;1;2;2;3"); } // empty and garbage jump + }; //---------------------------------------------------------