Crash when toggle mmrests after adding instruments (caused by page number text element)

• Aug 20, 2017 - 09:17
Reported version
3.0
Type
Functional
Severity
S2 - Critical
Status
closed
Project

ef25e60 / Windows7/10

1) "Untitled" score
2) "I" -> Add a few instruments eg 3 or 4 Flutes -> Ok
3) Press "M" twice

Result: crash


Comments

  • This issue appears on March,14 with this nitghtly: d9ff5a2

. This one works: e559a34

(note that is needed the first score has line breaks: that is the case of the "Untitled" default score)

Edit: I'm not sure about what I wrote here about the bug being in timeline, since I don't get this stack trace when run from qtcreator on linux, so disregard what I wrote here in this post:

The bug is in timeline.cpp:1296 according to stack trace...when call qlist.h:115 via updateView. JoshuaBonn should try to fix this now.

(I was actually testing gsok_nikos's code when tried this crash as a test...the backstrace stack is here: https://musescore.sp.backtrace.io/dashboard/musescore/project/MuseScore… although I guess backtrace is only available by invite currently...I've attaced .txt from that backtrace output.)

happens on latest master build 05e8a90

Attachment Size
5f.txt 24.03 KB

In reply to by ericfontainejazz

When running on my arch linux machine, I can sucessfully add one flute staff to the initial untitled score and press 'm' twice, however I only get the crash after adding another flute and press 'm' twice. Stack trace is:

1 ??
2 Ms::Element::canvasPos element.cpp 398 0x100efc491
3 Ms::Element::canvasBoundingRect element.h 252 0x1007499d1
4 Ms::Text::setProperty text.cpp 2713 0x1010642db
5 Ms::Text::styleChanged text.cpp 2857 0x101064c79
6 Ms::Page::styleChanged page.cpp 201 0x100fa0c44
7 Ms::updateStyle score.cpp 1195 0x100fcac54
8 Ms::Score::scanElements score.cpp 1694 0x100fcc659
9 Ms::Score::styleChanged score.cpp 1205 0x100fcac81
10 Ms::ChangeStyleVal::flip undo.cpp 1369 0x1010a5105
11 Ms::UndoCommand::redo undo.cpp 164 0x1010a0034
12 Ms::UndoStack::push undo.cpp 265 0x1010a061e
13 Ms::Score::undo score.cpp 3297 0x100fd4891
14 Ms::Score::cmdToggleMmrest cmd.cpp 3200 0x1010bb963
15 Ms::Score::::operator()(void) const cmd.cpp 3579 0x1010be5f1
16 std::_Function_handler>::_M_invoke(const std::_Any_data &) std_function.h 316 0x1010d2172
17 std::function::operator()() const std_function.h 706 0x1010df8ca
18 Ms::Score::cmd cmd.cpp 3593 0x1010c0c80
19 Ms::ScoreView::cmd scoreview.cpp 2222 0x10073bd3b
20 Ms::ScoreView::cmd scoreview.cpp 1678 0x10073851e
...

I don't see timeline in that stack trace, though.

In reply to by ericfontainejazz

same stack trace when add 3 or 4 flutes:

1 QGraphicsRectItem::boundingRect() const 0x7f2add5fc033
2 Ms::Element::canvasPos element.cpp 398 0x100efc491
3 Ms::Element::canvasBoundingRect element.h 252 0x1007499d1
4 Ms::Text::setProperty text.cpp 2713 0x1010642db
5 Ms::Text::styleChanged text.cpp 2857 0x101064c79
6 Ms::Page::styleChanged page.cpp 201 0x100fa0c44
7 Ms::updateStyle score.cpp 1195 0x100fcac54
8 Ms::Score::scanElements score.cpp 1694 0x100fcc659
9 Ms::Score::styleChanged score.cpp 1205 0x100fcac81
10 Ms::ChangeStyleVal::flip undo.cpp 1369 0x1010a5105
11 Ms::UndoCommand::redo undo.cpp 164 0x1010a0034
12 Ms::UndoStack::push undo.cpp 265 0x1010a061e
13 Ms::Score::undo score.cpp 3297 0x100fd4891
14 Ms::Score::cmdToggleMmrest cmd.cpp 3200 0x1010bb963
15 Ms::Score::::operator()(void) const cmd.cpp 3579 0x1010be5f1
16 std::_Function_handler>::_M_invoke(const std::_Any_data &) std_function.h 316 0x1010d2172
17 std::function::operator()() const std_function.h 706 0x1010df8ca
18 Ms::Score::cmd cmd.cpp 3593 0x1010c0c80
19 Ms::ScoreView::cmd scoreview.cpp 2222 0x10073bd3b
20 Ms::ScoreView::cmd scoreview.cpp 1678 0x10073851e
...

Title Crash when toggle mmrests after adding instruments Crash when toggle mmrests after adding instruments (caused by page number text element)

ok, looking in qtcreator I see that the element that is crashing is a Text element with text "2" if I had added 2 extra flutes, or is text "3" if I had added 3 or 4 flutes. This number I've determined is the last page number, because if I go to Format->General Style->Header/Footer and then remove the page number from the footer, then I no longer will get a crash when toggling 'm' with 2 to 4 flutes.