JoshuaBonn1 / MuseScore

MuseScore is an open source and free music notation software. For support, contribution, bug reports, visit MuseScore.org. Fork and make pull requests!
https://musescore.org
Other
0 stars 0 forks source link

SegFault in Timeline::drawGrid #15

Closed ericfont closed 6 years ago

ericfont commented 7 years ago

Tried this score https://musescore.com/user/14201696/scores/3029121 with your PR #3274 and got segfault in Timeline::drawGrid when line:

              doc.setHtml(part_list.at(row)->longName());

when row is 50. This might be a bug in someone else'e code, i haven't checked....but fyi here is the stack trace:

1   raise                                                                             0x7f4bb615b8c0 
2   abort                                                                             0x7f4bb615cf72 
3   QMessageLogger::fatal(const char *, ...) const                                    0x7f4bb6b039a8 
4   qt_assert_x(const char *, const char *, const char *, int)                        0x7f4bb6afeacb 
5   QList<Ms::Part *>::at                                      qlist.h           541  0x10087bf09    
6   Ms::Timeline::drawGrid                                     timeline.cpp      891  0x1009b1869    
7   Ms::Timeline::setScore                                     timeline.cpp      2217 0x1009ba7a8    
8   Ms::MuseScore::setCurrentScoreView                         musescore.cpp     1876 0x10095b4a5    
9   Ms::MuseScore::qt_static_metacall                          moc_musescore.cpp 743  0x100e4795d    
10  QMetaObject::activate(QObject *, int, int, void * *)                              0x7f4bb6d2c786 
11  Ms::ScoreTab::currentScoreViewChanged                      moc_scoretab.cpp  174  0x100e4ed00    
12  Ms::ScoreTab::setCurrent                                   scoretab.cpp      251  0x100acfdbf    
13  Ms::ScoreTab::qt_static_metacall                           moc_scoretab.cpp  103  0x100e4ea4c    
14  QMetaObject::activate(QObject *, int, int, void * *)                              0x7f4bb6d2c786 
15  QTabBar::currentChanged(int)                                                      0x7f4bbf45c2ff 
16  QTabBar::setCurrentIndex(int)                                                     0x7f4bbf460c10 
17  Ms::ScoreTab::setCurrentIndex                              scoretab.cpp      378  0x100ad0911    
18  Ms::MuseScore::setCurrentView                              musescore.cpp     1752 0x10095ab31    
19  Ms::MuseScore::setCurrentScoreView                         musescore.cpp     1740 0x10095aa98    
20  Ms::MuseScore::dropEvent                                   musescore.cpp     2017 0x10095bdc5    
... <More>                                                                                           

I found this by trying out scores from https://musescore.com/sheetmusic?parts=50 ...some of them crashed in places outside of your code...but I'm reporting this to you because Timeline was in the stack trace.

JoshuaBonn1 commented 7 years ago

Try it now with my latest amend. Hopefully this'll work.

ericfont commented 7 years ago

Briefly, what was wrong and what was the fix?

JoshuaBonn1 commented 7 years ago

Well, I don't know the overall problem as it was not halting the debugger on the issue, rather just closing me out. But, I believe the issue was that I was using staves when parts should have been used and it was causing some issues. After switching that, it worked fine.

JoshuaBonn1 commented 7 years ago

to the extent of my knowledge that is