Handle dlsym() failures in chainloaders better

If these ever fail (because the function names change, not that that
should happen anytime soon) then you'll now get the expected logging
output instead of it just printing an assertion failure to the terminal.
This commit is contained in:
Robbert van der Helm
2022-04-21 14:21:26 +02:00
parent 958007b56d
commit 89378e8862
4 changed files with 35 additions and 2 deletions
+4 -1
View File
@@ -94,7 +94,10 @@ bool initialize_library() {
do { \
(name) = \
reinterpret_cast<decltype(name)>(dlsym(library_handle, #name)); \
assert(name); \
if (!(name)) { \
log_failing_dlsym(yabridge_vst3_plugin_name, #name); \
return false; \
} \
} while (false)
LOAD_FUNCTION(yabridge_module_init);