Part not completely deleted

• Jul 25, 2013 - 14:25
Type
Functional
Severity
S2 - Critical
Status
closed
Project

1- Close all open scores;
2- Open parti.mscz from http://musescore.org/en/node/22051 ;
3- Click on each of the tabs of the parts and then on the tab of the root score;
4- With the root score in view (as it should after step 3) go to File -> Parts...;
5- Delete all the parts one by one and then press Ok;
6- Close the score and discard changes.
Result: After closing, one of the scores (which one seems to depend on the order by which scores where deleted or seen) of the parts is still visible; dragging works, but trying to click the measure to enter note entering mode brings a crash.

Nightly build rev. 2ef217d, Windows 8


Comments

Posted a pull request:
https://github.com/musescore/MuseScore/pull/448
Since the stack was changing inside the loop, if more parts were deleted at the same time the exit condition was reached before all the scoreviews corresponding to deleted parts were actually queued to be deleted.
By making the loop going "backwards" from the max value of i to 0, all scoreviews are scanned, without problems of access violation if the size of stack is decreasing because of deleted scoreviews.