Crash when multi-measure rests are enabled and press End
Reported version
3.x-dev
Priority
P0 - Critical
Type
Functional
Frequency
Once
Severity
S2 - Critical
Reproducibility
Always
Status
closed
Regression
Yes
Workaround
No
Project
v-3.3-RC on Windows 10 crash report sent with my name included (mike320)
Create a score
Enable multi-measure rests (I know that if the score ends with a multi-measure rest the crash occurs)
Press End
Crash!
Fix version
3.3.3
Comments
Confirm, it's as simple to reproduce as:
1) default empty score
2) press "M"
3) press "End"
Crash happens in ScoreView::pageEnd(), we grab score()->last() which is the last measurebase and then try to access its system, but the last measure has no system because it is covered by an mmrest. I'll see about a fix.
Actually, it looks like other page / screen navigation commands may have similar issues, maybe someone else wants to take a look. Some of it at least seems to be a regression in 3.3 - see https://github.com/musescore/MuseScore/pull/4803
Confirmed. Not an issue with 3.2.3 but with 3.3 RC, so a regression that needs fixing before 3.3 gets released
This issue appears in last August.
This would confirm I guess that the origin would indeed be here ? https://github.com/musescore/MuseScore/pull/4803
( I see two other commits this day about navigation, but less likely or not at all involved ?)
I see 2 possible fixes for this particular crash
score()->lastMeasureMM()
instead ofscore()->last()
lm->system()
to be not NULL before accessinglm->system()->page()->width()
Or even both.
screenNext()
,screenPrev()
,pageNext()
,pagePrev()
andpageTop()
seem to not be affected by this issue (i.e. don't crash), justpageEnd()
, only that accesseslm->system()
see https://github.com/musescore/MuseScore/pull/5415. As
score()->last()
works just fine inscreenNext()
,screenPrev()
,pageNext()
,pagePrev()
andpageTop()
, I went for option 2Fixed in branch master, commit b84d499896
_fix #296034: Crash when multi-measure rests are enabled and press End
also consistenltly use
lastMeasureMM()
rather thanlast()
in otherplaces of that file_
Fixed in branch master, commit 63445133b5
_Merge pull request #5415 from Jojo-Schmitz/page-end-crash
fix #296034: Crash when multi-measure rests are enabled and press End_
Automatically closed -- issue fixed for 2 weeks with no activity.