Fix embed use-after-free, restore golden fixture + refs tests, drop dead note_entry

This commit is contained in:
2026-07-30 08:01:22 -04:00
parent 8d4ccbf841
commit e304f2b031
13 changed files with 241 additions and 244 deletions
+6 -3
View File
@@ -78,10 +78,13 @@ void ReaSamplerEmbed::refreshLoaded() {
const InstrumentParams params = processor_->instrumentParams();
if (params.rootOverride) {
rootNote_ = *params.rootOverride;
} else if (const SelectedSample* ref = findRef(processor_->sampleRefs(), loadedId_)) {
rootNote_ = ref->rootNote;
} else {
rootNote_ = 60;
const SampleRefs refs = processor_->sampleRefs();
if (const SelectedSample* ref = findRef(refs, loadedId_)) {
rootNote_ = ref->rootNote;
} else {
rootNote_ = 60;
}
}
}