mirror of
https://github.com/robbert-vdh/yabridge.git
synced 2026-05-09 20:29:10 +02:00
Clarify group host plugin removal process better
This commit is contained in:
@@ -121,9 +121,11 @@ void GroupBridge::handle_plugin_dispatch(const GroupRequest request) {
|
|||||||
logger.log("'" + request.plugin_path + "' has exited");
|
logger.log("'" + request.plugin_path + "' has exited");
|
||||||
|
|
||||||
// After the plugin has exited we'll remove this thread's plugin from the
|
// After the plugin has exited we'll remove this thread's plugin from the
|
||||||
// active plugins. This is done within the IO context so we can properly
|
// active plugins. This is done within the IO context because the call to
|
||||||
// join the thread again. If no active plugins remain, then we'll terminate
|
// `FreeLibrary()` has to be done from the main thread, or else we'll
|
||||||
// the process.
|
// potentially corrupt our heap. This way we can also properly join the
|
||||||
|
// thread again. If no active plugins remain, then we'll terminate the
|
||||||
|
// process.
|
||||||
boost::asio::post(plugin_context, [&, request]() {
|
boost::asio::post(plugin_context, [&, request]() {
|
||||||
std::lock_guard lock(active_plugins_mutex);
|
std::lock_guard lock(active_plugins_mutex);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user