Selecting a measure then applying grace notes causes crash

• Jul 12, 2019 - 16:31
Reported version
3.2
Priority
P0 - Critical
Type
Functional
Frequency
Once
Severity
S2 - Critical
Reproducibility
Always
Status
closed
Regression
No
Workaround
No
Project
Tags

Win 7/10. MS 3.2.3

  1. Open the attached file.
  2. Select measure 2 (by clicking on a blank space within the measure).
  3. Press right slash button to apply acciaccaturas.
  4. If that doesn't cause a crash, do the same with measure 1, then measure 3, then 4.
  5. If still no crash after all four measures have been selected, close the program (not just the file) and reload (don't chose to restore the session).
  6. Try the same sequence again. If still no crash, close and reopen the program, then repeat with a different order of measures and so on.
Attachment Size
acciaccaturas_crash.mscz 4.14 KB

Comments

Priority P0 - Critical
Tags View Changes

It crashed for me first try :-) It's on the loop in cmdAddGrace(). My guess is the list we are iterating on (selection().elements()) is being modified within the loop, and the solution is to simply make a copy of the list to iterate on as we do a bunch of other places to avoid similar crashes.

Status PR created fixed

Fixed in branch master, commit f61e9814ba

_fix #292079: Prevent crash when adding grace notes to a selected measure

Copy selected elements and iterate over the copied list since the
original list might be changed during the execution of the loop._

Fix version
3.3.1