Skip to content

Commit 3c47c49

Browse files
committed
Fix build, make sure to not enable OSC
Signed-off-by: falkTX <falktx@falktx.com>
1 parent 3c5793b commit 3c47c49

2 files changed

Lines changed: 20 additions & 5 deletions

File tree

carla

main.cpp

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -72,22 +72,37 @@ int main(int argc, char *argv[])
7272

7373
const CarlaHostHandle handle = carla_standalone_host_init();
7474

75-
if (handle == nullptr || !carla_engine_init(handle, "JACK", "Chibi"))
75+
if (handle == nullptr)
7676
{
77-
QMessageBox::critical(nullptr, "Error", carla_get_last_error(handle));
77+
QMessageBox::critical(nullptr, "Error", carla_get_last_error(nullptr));
7878
return 1;
7979
}
8080

8181
carla_set_engine_option(handle, ENGINE_OPTION_OSC_ENABLED, 0, nullptr);
82+
carla_set_engine_option(handle, ENGINE_OPTION_OSC_PORT_TCP, -1, nullptr);
83+
carla_set_engine_option(handle, ENGINE_OPTION_OSC_PORT_UDP, -1, nullptr);
8284
carla_set_engine_option(handle, ENGINE_OPTION_PATH_BINARIES, 0, carla_get_library_folder());
8385
carla_set_engine_option(handle, ENGINE_OPTION_PREFER_UI_BRIDGES, 0, nullptr);
8486

85-
// TODO check CLI args and use it instead of plugin list dialog
87+
if (!carla_engine_init(handle, "JACK", "Chibi"))
88+
{
89+
QMessageBox::critical(nullptr, "Error", carla_get_last_error(handle));
90+
return 1;
91+
}
8692

87-
const PluginListDialogResults* const res = carla_frontend_createAndExecPluginListDialog(nullptr);
93+
// TODO check CLI args and use it instead of plugin list dialog
8894

8995
int r = 1;
9096

97+
const HostSettings hostSettings = {};
98+
PluginListDialog* const dialog = carla_frontend_createPluginListDialog(nullptr, &hostSettings);
99+
const PluginListDialogResults* res;
100+
101+
if (dialog == nullptr)
102+
goto cleanup;
103+
104+
res = carla_frontend_execPluginListDialog(dialog);
105+
91106
if (res == nullptr)
92107
goto cleanup;
93108

0 commit comments

Comments
 (0)