Skip to content

Commit

Permalink
Merge pull request #5849 from Jojo-Schmitz/compiler-warnings
Browse files Browse the repository at this point in the history
fix compiler warnings
  • Loading branch information
anatoly-os committed Apr 14, 2020
2 parents 2a1b76e + 17a978a commit 8198aeb
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 12 deletions.
18 changes: 9 additions & 9 deletions libmscore/cmd.cpp
Expand Up @@ -3239,21 +3239,21 @@ Segment* Score::setChord(Segment* segment, int track, Chord* chordTemplate, Frac
//and add the tie to score
const std::vector<Note*> notes = chord->notes();
if (addTie) {
for (size_t i = 0; i < notes.size(); ++i) {
tie[i]->setEndNote(notes[i]);
notes[i]->setTieBack(tie[i]);
undoAddElement(tie[i]);
for (size_t j = 0; j < notes.size(); ++j) {
tie[j]->setEndNote(notes[j]);
notes[j]->setTieBack(tie[j]);
undoAddElement(tie[j]);
}
addTie = false;
}
//if we're not the last element in the duration list,
//set tie forward
if (i+1 < n) {
for (size_t i = 0; i < notes.size(); ++i) {
tie[i] = new Tie(this);
tie[i]->setStartNote(notes[i]);
tie[i]->setTrack(track);
notes[i]->setTieFor(tie[i]);
for (size_t j = 0; j < notes.size(); ++j) {
tie[j] = new Tie(this);
tie[j]->setStartNote(notes[j]);
tie[j]->setTrack(track);
notes[j]->setTieFor(tie[j]);
addTie = true;
}
}
Expand Down
6 changes: 3 additions & 3 deletions mscore/scoretab.cpp
Expand Up @@ -167,12 +167,12 @@ TabScoreView* ScoreTab::tabScoreView(int idx)
return nullptr;
}

QVariant data = tab->tabData(idx);
IF_ASSERT_FAILED(data.isValid()) {
QVariant tabData = tab->tabData(idx);
IF_ASSERT_FAILED(tabData.isValid()) {
return nullptr;
}

return static_cast<TabScoreView*>(data.value<void*>());
return static_cast<TabScoreView*>(tabData.value<void*>());
}

//---------------------------------------------------------
Expand Down

0 comments on commit 8198aeb

Please sign in to comment.