Skip to content

Commit

Permalink
Merged revision(s) 21556 from trunk/OpenMPT:
Browse files Browse the repository at this point in the history
[Fix] Avoid crash in plugin bridge if plugin changes channel configuration without telling us (observed with Surge XT via vst3ishell, https://bugs.openmpt.org/view.php?id=1807).
........


git-svn-id: https://source.openmpt.org/svn/openmpt/branches/OpenMPT-1.31@21557 56274372-70c3-4bfc-bfc3-4c3a0b034d27
  • Loading branch information
sagamusix committed Aug 31, 2024
1 parent 44b604e commit b6ac0e8
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pluginBridge/Bridge.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -478,6 +478,9 @@ void PluginBridge::DispatchToPlugin(DispatchMsg &msg)
// [value]: 0 means "turn off", 1 means "turn on"
::SetThreadPriority(m_audioThread, msg.value ? THREAD_PRIORITY_ABOVE_NORMAL : THREAD_PRIORITY_NORMAL);
m_sharedMem->tailSize = static_cast<int32>(Dispatch(effGetTailSize, 0, 0, nullptr, 0.0f));
// Plugin should tell us if number of channels changes through audioMasterIOChanged, but Surge XT via vst3ishell has been observed not to do that.
if(msg.value)
DispatchToHost(audioMasterVendorSpecific, kVendorOpenMPT, kUpdateProcessingBuffer, nullptr, 0.0f);
break;

case effEditGetRect:
Expand Down

0 comments on commit b6ac0e8

Please sign in to comment.