Jazz Big Band and Jazz Combo Templates crash MuseScore

• Jul 21, 2012 - 15:34
Type
Functional
Severity
S2 - Critical
Status
closed
Project

This template crashes MuseScore both when you use it from the Create Score dialogue and when you open it from the Templates directory.

I'm currently invstigating why.

It could be because there are no bars when you open it.

More info later.

WindowsXP Pro SP3/ MuseScore 2.0 R3432cdc


Comments

I never fully understood how templates were supposed to be created, but found if there were measures - say, 8 - in the score when I saved it as a template, I got a double bar at that eight bar in any score created from the template. So I assumed the correct way way to make templates was to delete all measures.

Title Jazz Big Band Template crashes MuseScore Jazz Big Band and Jazz Combo Templates crash MuseScore

It wasn't that anyway Marc - I still haven't established what is causing the crash, but there is something in there MuseScore doesn't like.

The Jazz Combo template also crashed MuseScore 2.0 - title amended accordinlgy

Just for info:

Checking Jazz Big Band template:

The crash happens in file libmscore/read114.cpp, function Score::read114() at line 223, when the code is attempting to locate the measure where clef(s) is/are placed (presumably the initial clef(s) as file ticks are at 0). If I understand correctly, there are no measures in the file and the code does not check that no measure is actually found => null pointer accessed => crash.

A very similar code tries to match measures with keys a few lines later: this also has to be corrected.

Even if templates are required to have some measure in them, the program should recover more gracefully if they do not; so, fixing the templates is not enough.

M.

Hmm, so if templates are supposed to have measures in them, what are you supposed to do to avoid having extra double bars placed in scores created from them? When I initially saved these templates with 4 measures in them, all generated scores longer than that had double bars after the fourth measure. That's what made me assume I was supposed to delete bars before saving the template. I also had a memory of Finale working that way, so I maybe I just didn't try hard enough to find alternatives? Maybe I'm supposed to have one and only one measure and there is a special case made for that?

Having single-measure templates might be a working work-around, but still the program should handle a no-measure template in a more graceful way than crashing!

And/Or it should refuse to save a score without any measure, if this is problematic to handle (I have not tried but I assume that even loading a no-measure score, instead of a template, would crash the program).

M.

I haven't looked at this recently. Until I hear otherwise, my understanding remains that templates are *supposed* to be empty - that was the only way they ever worked in 1.X - so failure of MuseScore to handle existing templates is a bug in the program. So I hadn't gone in and updated these templates to add a measure as a workaround. If someone tells me that is now the correct way for templates to work, and that it will in fact work now, I'm happy to update the templates. I actually plan to check in some changes at some point fairly soon anyhow to take advantage of the chord symbol stuff I've been working on as well as updating all the style settings for 2.0.

The templates no longer crash MuseScore. Nevertheless, it would be wise to create new templates for 2.0 from scratch since there are other problems with empty scores with parts.

I was definitely planning on redoing these anyhow, to pick up new style settings etc.

So should templates not be empty any more? As I mentioned, non-empty templates never used to work correctly, as your generated score would get a double bar in whatever was the last bar of the template.