Browse Source

Misc code fixes as reported by clang-analyzer

tags/v0.9.0
falkTX 12 years ago
parent
commit
87a59d1c65
9 changed files with 128 additions and 124 deletions
  1. +5
    -1
      c++/carla-bridge/carla_bridge_osc.cpp
  2. +0
    -1
      c++/carla-bridge/carla_bridge_plugin.cpp
  3. +1
    -1
      c++/carla-engine/carla_engine_osc.cpp
  4. +0
    -2
      c++/carla-plugin/carla_plugin.cpp
  5. +9
    -5
      c++/carla-plugin/dssi.cpp
  6. +2
    -2
      c++/carla-plugin/ladspa.cpp
  7. +77
    -83
      c++/carla-plugin/lv2.cpp
  8. +33
    -28
      c++/carla-plugin/vst.cpp
  9. +1
    -1
      c++/carla-utils/carla_lib_utils.hpp

+ 5
- 1
c++/carla-bridge/carla_bridge_osc.cpp View File

@@ -120,10 +120,14 @@ int CarlaBridgeOsc::handleMessage(const char* const path, const int argc, const
qDebug("CarlaBridgeOsc::handleMessage(\"%s\", %i, %p, \"%s\", %p)", path, argc, argv, types, msg);
CARLA_ASSERT(m_server);
CARLA_ASSERT(m_serverPath);
CARLA_ASSERT(m_name);
CARLA_ASSERT(path);

if (! (m_name && path))
return 1;

// Check if message is for this client
if ((! path) || strlen(path) <= m_nameSize || strncmp(path+1, m_name, m_nameSize) != 0)
if (strlen(path) <= m_nameSize || strncmp(path+1, m_name, m_nameSize) != 0)
{
qWarning("CarlaBridgeOsc::handleMessage() - message not for this client: '%s' != '/%s/'", path, m_name);
return 1;


+ 0
- 1
c++/carla-bridge/carla_bridge_plugin.cpp View File

@@ -779,7 +779,6 @@ int main(int argc, char* argv[])
itype = CarlaBackend::PLUGIN_VST;
else
{
itype = CarlaBackend::PLUGIN_NONE;
qWarning("Invalid plugin type '%s'", stype);
return 1;
}


+ 1
- 1
c++/carla-engine/carla_engine_osc.cpp View File

@@ -155,7 +155,7 @@ int CarlaEngineOsc::handleMessage(const char* const path, const int argc, const
CARLA_ASSERT(m_name);
CARLA_ASSERT(path);

if (! path)
if (! (m_name && path))
return 1;

#ifndef BUILD_BRIDGE


+ 0
- 2
c++/carla-plugin/carla_plugin.cpp View File

@@ -810,8 +810,6 @@ void CarlaPlugin::setMidiProgram(int32_t index, const bool sendGui, const bool s

void CarlaPlugin::setMidiProgramById(const uint32_t bank, const uint32_t program, const bool sendGui, const bool sendOsc, const bool sendCallback, const bool block)
{
CARLA_ASSERT(program < 128);

for (uint32_t i=0; i < midiprog.count; i++)
{
if (midiprog.data[i].bank == bank && midiprog.data[i].program == program)


+ 9
- 5
c++/carla-plugin/dssi.cpp View File

@@ -62,8 +62,13 @@ public:

if (osc.thread)
{
#ifndef BUILD_BRIDGE
const uint oscUiTimeout = x_engine->getOptions().oscUiTimeout;
#else
const uint oscUiTimeout = 40;
#endif
// Wait a bit first, try safe quit, then force kill
if (osc.thread->isRunning() && ! osc.thread->wait(40 * 100)) // x_engine->getOptions().oscUiTimeout
if (osc.thread->isRunning() && ! osc.thread->wait(oscUiTimeout))
{
qWarning("Failed to properly stop DSSI GUI thread");
osc.thread->terminate();
@@ -108,7 +113,7 @@ public:
{
CARLA_ASSERT(ldescriptor);

return ldescriptor->UniqueID;
return ldescriptor ? ldescriptor->UniqueID : 0;
}

// -------------------------------------------------------------------
@@ -801,12 +806,11 @@ public:
{
const DSSI_Program_Descriptor* const pdesc = descriptor->get_program(handle, i);
CARLA_ASSERT(pdesc);
CARLA_ASSERT(pdesc->Program < 128);
CARLA_ASSERT(pdesc->Name);

midiprog.data[i].bank = pdesc->Bank;
midiprog.data[i].program = pdesc->Program;
midiprog.data[i].name = strdup(pdesc->Name);
midiprog.data[i].name = strdup(pdesc->Name ? pdesc->Name : "");
}

#ifndef BUILD_BRIDGE
@@ -1317,7 +1321,7 @@ public:
bool do_balance = (m_hints & PLUGIN_CAN_BALANCE) > 0 && (x_balanceLeft != -1.0 || x_balanceRight != 1.0);

double bal_rangeL, bal_rangeR;
float bufValue, oldBufLeft[do_balance ? frames : 0];
float bufValue, oldBufLeft[do_balance ? frames : 1];

for (i=0; i < aOut.count; i++)
{


+ 2
- 2
c++/carla-plugin/ladspa.cpp View File

@@ -120,7 +120,7 @@ public:
{
CARLA_ASSERT(descriptor);

return descriptor->UniqueID;
return descriptor ? descriptor->UniqueID : 0;
}

// -------------------------------------------------------------------
@@ -993,7 +993,7 @@ public:
bool do_balance = (m_hints & PLUGIN_CAN_BALANCE) > 0 && (x_balanceLeft != -1.0 || x_balanceRight != 1.0);

double bal_rangeL, bal_rangeR;
float bufValue, oldBufLeft[do_balance ? frames : 0];
float bufValue, oldBufLeft[do_balance ? frames : 1];

for (i=0; i < aOut.count; i++)
{


+ 77
- 83
c++/carla-plugin/lv2.cpp View File

@@ -341,11 +341,15 @@ public:
break;

case GUI_EXTERNAL_OSC:
#ifndef BUILD_BRIDGE
if (osc.thread)
{
#ifndef BUILD_BRIDGE
const uint oscUiTimeout = x_engine->getOptions().oscUiTimeout;
#else
const uint oscUiTimeout = 40;
#endif
// Wait a bit first, try safe quit, then force kill
if (osc.thread->isRunning() && ! osc.thread->wait(x_engine->getOptions().oscUiTimeout * 100))
if (osc.thread->isRunning() && ! osc.thread->wait(oscUiTimeout))
{
qWarning("Failed to properly stop LV2 OSC GUI thread");
osc.thread->terminate();
@@ -353,7 +357,6 @@ public:

delete osc.thread;
}
#endif
break;
}

@@ -499,32 +502,35 @@ public:
{
CARLA_ASSERT(rdf_descriptor);

LV2_Property category = rdf_descriptor->Type;

if (LV2_IS_DELAY(category))
return PLUGIN_CATEGORY_DELAY;
if (LV2_IS_DISTORTION(category))
return PLUGIN_CATEGORY_OTHER;
if (LV2_IS_DYNAMICS(category))
return PLUGIN_CATEGORY_DYNAMICS;
if (LV2_IS_EQ(category))
return PLUGIN_CATEGORY_EQ;
if (LV2_IS_FILTER(category))
return PLUGIN_CATEGORY_FILTER;
if (LV2_IS_GENERATOR(category))
return PLUGIN_CATEGORY_SYNTH;
if (LV2_IS_MODULATOR(category))
return PLUGIN_CATEGORY_MODULATOR;
if (LV2_IS_REVERB(category))
return PLUGIN_CATEGORY_DELAY;
if (LV2_IS_SIMULATOR(category))
return PLUGIN_CATEGORY_OTHER;
if (LV2_IS_SPATIAL(category))
return PLUGIN_CATEGORY_OTHER;
if (LV2_IS_SPECTRAL(category))
return PLUGIN_CATEGORY_UTILITY;
if (LV2_IS_UTILITY(category))
return PLUGIN_CATEGORY_UTILITY;
if (rdf_descriptor)
{
LV2_Property category = rdf_descriptor->Type;

if (LV2_IS_DELAY(category))
return PLUGIN_CATEGORY_DELAY;
if (LV2_IS_DISTORTION(category))
return PLUGIN_CATEGORY_OTHER;
if (LV2_IS_DYNAMICS(category))
return PLUGIN_CATEGORY_DYNAMICS;
if (LV2_IS_EQ(category))
return PLUGIN_CATEGORY_EQ;
if (LV2_IS_FILTER(category))
return PLUGIN_CATEGORY_FILTER;
if (LV2_IS_GENERATOR(category))
return PLUGIN_CATEGORY_SYNTH;
if (LV2_IS_MODULATOR(category))
return PLUGIN_CATEGORY_MODULATOR;
if (LV2_IS_REVERB(category))
return PLUGIN_CATEGORY_DELAY;
if (LV2_IS_SIMULATOR(category))
return PLUGIN_CATEGORY_OTHER;
if (LV2_IS_SPATIAL(category))
return PLUGIN_CATEGORY_OTHER;
if (LV2_IS_SPECTRAL(category))
return PLUGIN_CATEGORY_UTILITY;
if (LV2_IS_UTILITY(category))
return PLUGIN_CATEGORY_UTILITY;
}

return getPluginCategoryFromName(m_name);
}
@@ -533,7 +539,7 @@ public:
{
CARLA_ASSERT(rdf_descriptor);

return rdf_descriptor->UniqueID;
return rdf_descriptor ? rdf_descriptor->UniqueID : 0;
}

// -------------------------------------------------------------------
@@ -1031,7 +1037,6 @@ public:
break;

case GUI_EXTERNAL_OSC:
#ifndef BUILD_BRIDGE
CARLA_ASSERT(osc.thread);

if (! osc.thread)
@@ -1056,20 +1061,13 @@ public:
if (! osc.thread->wait(500))
osc.thread->quit();
}
#endif
break;
}
}

void idleGui()
{
#ifdef BUILD_BRIDGE
const bool haveUI = (gui.type != GUI_EXTERNAL_OSC && ui.handle && ui.descriptor);
#else
const bool haveUI = (gui.type == GUI_EXTERNAL_OSC && osc.data.target) || (ui.handle && ui.descriptor);
#endif

if (haveUI)
if ((gui.type == GUI_EXTERNAL_OSC && osc.data.target) || (ui.handle && ui.descriptor))
{
// Update event ports
if (! atomQueueOut.isEmpty())
@@ -1082,14 +1080,12 @@ public:

while (queue.get(&portIndex, &atom, false))
{
#ifndef BUILD_BRIDGE
if (gui.type == GUI_EXTERNAL_OSC)
{
QByteArray chunk((const char*)atom, sizeof(LV2_Atom) + atom->size);
osc_send_lv2_transfer_event(&osc.data, portIndex, getCustomURIString(atom->type), chunk.toBase64().constData());
}
else
#endif
{
if (ui.descriptor->port_event)
ui.descriptor->port_event(ui.handle, portIndex, atom->size, CARLA_URI_MAP_ID_ATOM_TRANSFER_EVENT, atom);
@@ -1859,12 +1855,11 @@ public:
{
const LV2_Program_Descriptor* const pdesc = ext.programs->get_program(handle, i);
CARLA_ASSERT(pdesc);
CARLA_ASSERT(pdesc->program < 128);
CARLA_ASSERT(pdesc->name);

midiprog.data[i].bank = pdesc->bank;
midiprog.data[i].program = pdesc->program;
midiprog.data[i].name = strdup(pdesc->name);
midiprog.data[i].name = strdup(pdesc->name ? pdesc->name : "");
}

#ifndef BUILD_BRIDGE
@@ -2559,7 +2554,7 @@ public:
}
}

midiEventCount = MAX_MIDI_CHANNELS*2;
//midiEventCount = MAX_MIDI_CHANNELS*2;
}

if (m_latency > 0)
@@ -2620,7 +2615,7 @@ public:
bool do_balance = (m_hints & PLUGIN_CAN_BALANCE) > 0 && (x_balanceLeft != -1.0 || x_balanceRight != 1.0);

double bal_rangeL, bal_rangeR;
float bufValue, oldBufLeft[do_balance ? frames : 0];
float bufValue, oldBufLeft[do_balance ? frames : 1];

for (i=0; i < aOut.count; i++)
{
@@ -2845,14 +2840,12 @@ public:
if (index >= param.count)
return;

#ifndef BUILD_BRIDGE
if (gui.type == GUI_EXTERNAL_OSC)
{
if (osc.data.target)
osc_send_control(&osc.data, param.data[index].rindex, value);
}
else
#endif
{
if (ui.handle && ui.descriptor && ui.descriptor->port_event)
{
@@ -2869,14 +2862,12 @@ public:
if (index >= midiprog.count)
return;

#ifndef BUILD_BRIDGE
if (gui.type == GUI_EXTERNAL_OSC)
{
if (osc.data.target)
osc_send_midi_program(&osc.data, midiprog.data[index].bank, midiprog.data[index].program);
}
else
#endif
{
if (ext.uiprograms)
ext.uiprograms->select_program(ui.handle, midiprog.data[index].bank, midiprog.data[index].program);
@@ -2889,7 +2880,6 @@ public:
CARLA_ASSERT(note < 128);
CARLA_ASSERT(velo > 0 && velo < 128);

#ifndef BUILD_BRIDGE
if (gui.type == GUI_EXTERNAL_OSC)
{
if (osc.data.target)
@@ -2902,7 +2892,6 @@ public:
}
}
else
#endif
{
if (ui.handle && ui.descriptor && ui.descriptor->port_event)
{
@@ -2924,7 +2913,6 @@ public:
CARLA_ASSERT(channel < 16);
CARLA_ASSERT(note < 128);

#ifndef BUILD_BRIDGE
if (gui.type == GUI_EXTERNAL_OSC)
{
if (osc.data.target)
@@ -2936,7 +2924,6 @@ public:
}
}
else
#endif
{
if (ui.handle && ui.descriptor && ui.descriptor->port_event)
{
@@ -3139,7 +3126,7 @@ public:
if (prog.names[index])
free((void*)prog.names[index]);

prog.names[index] = strdup(progName);
prog.names[index] = strdup(progName ? progName : "");
}
}

@@ -3155,12 +3142,24 @@ public:
const char* const uriKey = getCustomURIString(key);

// do basic checks
if (! uriKey)
if (! key)
{
qWarning("Lv2Plugin::handleStateStore(%i, %p, " P_SIZE ", %i, %i) - invalid key", key, value, size, type, flags);
return LV2_STATE_ERR_NO_PROPERTY;
}

if (! value)
{
qWarning("Lv2Plugin::handleStateStore(%i, %p, " P_SIZE ", %i, %i) - invalid value", key, value, size, type, flags);
return LV2_STATE_ERR_NO_PROPERTY;
}

if (! uriKey)
{
qWarning("Lv2Plugin::handleStateStore(%i, %p, " P_SIZE ", %i, %i) - invalid key URI", key, value, size, type, flags);
return LV2_STATE_ERR_NO_PROPERTY;
}

if (! flags & LV2_STATE_IS_POD)
{
qWarning("Lv2Plugin::handleStateStore(%i, %p, " P_SIZE ", %i, %i) - invalid flags", key, value, size, type, flags);
@@ -3178,7 +3177,8 @@ public:
{
if (strcmp(custom[i].key, uriKey) == 0)
{
free((void*)custom[i].value);
if (custom[i].value)
free((void*)custom[i].value);

if (strcmp(stype, LV2_ATOM__String) == 0 || strcmp(stype, LV2_ATOM__Path) == 0)
custom[i].value = strdup((const char*)value);
@@ -3337,7 +3337,7 @@ public:
CARLA_ASSERT(buffer);
CARLA_ASSERT(bufferSize == sizeof(float));

if (bufferSize != sizeof(float))
if (bufferSize != sizeof(float) || ! buffer)
return;

float value = *(float*)buffer;
@@ -3352,6 +3352,9 @@ public:
{
CARLA_ASSERT(buffer);

if (! buffer)
return;

const LV2_Atom* const atom = (const LV2_Atom*)buffer;
handleTransferAtom(rindex, atom);
}
@@ -3359,6 +3362,9 @@ public:
{
CARLA_ASSERT(buffer);

if (! buffer)
return;

const LV2_Atom* const atom = (const LV2_Atom*)buffer;
handleTransferEvent(rindex, atom);
}
@@ -3366,9 +3372,9 @@ public:

// -------------------------------------------------------------------

#ifndef BUILD_BRIDGE
const char* getUiBridgePath(const LV2_Property type)
{
#ifndef BUILD_BRIDGE
const CarlaEngineOptions options(x_engine->getOptions());

switch (type)
@@ -3388,6 +3394,10 @@ public:
default:
return nullptr;
}
#else
return nullptr;
Q_UNUSED(type);
#endif
}

bool isUiBridgeable(const uint32_t uiId)
@@ -3408,7 +3418,6 @@ public:

return true;
}
#endif

bool isUiResizable()
{
@@ -3484,8 +3493,8 @@ public:

uint32_t portIndex = evIn.count > 0 ? evIn.data[0].rindex : 0;

const LV2_Atom* const atom = lv2_atom_forge_deref(&forge, ref);
ui.descriptor->port_event(ui.handle, portIndex, atom->size, CARLA_URI_MAP_ID_ATOM_TRANSFER_EVENT, atom);
if (const LV2_Atom* const atom = lv2_atom_forge_deref(&forge, ref))
ui.descriptor->port_event(ui.handle, portIndex, atom->size, CARLA_URI_MAP_ID_ATOM_TRANSFER_EVENT, atom);

free((void*)chunk.buf);
sratom_free(sratom);
@@ -4197,7 +4206,9 @@ public:
int eQt4, eCocoa, eHWND, eX11, eGtk2, eGtk3, iCocoa, iHWND, iX11, iQt4, iExt, iSuil, iFinal;
eQt4 = eCocoa = eHWND = eX11 = eGtk2 = eGtk3 = iQt4 = iCocoa = iHWND = iX11 = iExt = iSuil = iFinal = -1;

#ifndef BUILD_BRIDGE
#ifdef BUILD_BRIDGE
const bool preferUiBridges = false;
#else
const bool preferUiBridges = x_engine->getOptions().preferUiBridges;
#endif

@@ -4206,59 +4217,46 @@ public:
switch (rdf_descriptor->UIs[i].Type)
{
case LV2_UI_QT4:
#ifndef BUILD_BRIDGE
if (isUiBridgeable(i) && preferUiBridges)
eQt4 = i;
#endif
iQt4 = i;
break;

case LV2_UI_COCOA:
#ifndef BUILD_BRIDGE
if (isUiBridgeable(i) && preferUiBridges)
eCocoa = i;
#endif
iCocoa = i;
break;

case LV2_UI_WINDOWS:
#ifndef BUILD_BRIDGE
if (isUiBridgeable(i) && preferUiBridges)
eHWND = i;
#endif
iHWND = i;
break;

case LV2_UI_X11:
#ifndef BUILD_BRIDGE
if (isUiBridgeable(i) && preferUiBridges)
eX11 = i;
#endif
iX11 = i;
break;

case LV2_UI_GTK2:
#ifdef BUILD_BRIDGE
if (false)
#else
# ifdef WANT_SUIL
#ifdef WANT_SUIL
if (isUiBridgeable(i) && preferUiBridges)
# else
eGtk2 = i;
#else
if (isUiBridgeable(i))
# endif
#endif
eGtk2 = i;
#endif
#ifdef WANT_SUIL
iSuil = i;
#endif
break;

#ifndef BUILD_BRIDGE
case LV2_UI_GTK3:
if (isUiBridgeable(i))
eGtk3 = i;
break;
#endif

case LV2_UI_EXTERNAL:
case LV2_UI_OLD_EXTERNAL:
@@ -4295,9 +4293,7 @@ public:
else if (iSuil >= 0)
iFinal = iSuil;

#ifndef BUILD_BRIDGE
const bool isBridged = (iFinal == eQt4 || iFinal == eCocoa || iFinal == eHWND || iFinal == eX11 || iFinal == eGtk2 || iFinal == eGtk3);
#endif
#ifdef WANT_SUIL
const bool isSuil = (iFinal == iSuil && !isBridged);
#endif
@@ -4391,7 +4387,6 @@ public:

const LV2_Property uiType = ui.rdf_descriptor->Type;

#ifndef BUILD_BRIDGE
if (isBridged)
{
// -------------------------------------------------------
@@ -4405,7 +4400,6 @@ public:
}
}
else
#endif
{
// -------------------------------------------------------
// initialize ui features


+ 33
- 28
c++/carla-plugin/vst.cpp View File

@@ -94,11 +94,15 @@ public:

if (gui.type == GUI_EXTERNAL_OSC)
{
#ifndef BUILD_BRIDGE
if (osc.thread)
{
#ifndef BUILD_BRIDGE
const uint oscUiTimeout = x_engine->getOptions().oscUiTimeout;
#else
const uint oscUiTimeout = 40;
#endif
// Wait a bit first, try safe quit, then force kill
if (osc.thread->isRunning() && ! osc.thread->wait(x_engine->getOptions().oscUiTimeout * 100))
if (osc.thread->isRunning() && ! osc.thread->wait(oscUiTimeout))
{
qWarning("Failed to properly stop VST OSC GUI thread");
osc.thread->terminate();
@@ -106,7 +110,6 @@ public:

delete osc.thread;
}
#endif
}
else
effect->dispatcher(effect, effEditClose, 0, 0, nullptr, 0.0f);
@@ -127,26 +130,29 @@ public:
{
CARLA_ASSERT(effect);

intptr_t category = effect->dispatcher(effect, effGetPlugCategory, 0, 0, nullptr, 0.0f);

switch (category)
if (effect)
{
case kPlugCategSynth:
return PLUGIN_CATEGORY_SYNTH;
case kPlugCategAnalysis:
return PLUGIN_CATEGORY_UTILITY;
case kPlugCategMastering:
return PLUGIN_CATEGORY_DYNAMICS;
case kPlugCategRoomFx:
return PLUGIN_CATEGORY_DELAY;
case kPlugCategRestoration:
return PLUGIN_CATEGORY_UTILITY;
case kPlugCategGenerator:
return PLUGIN_CATEGORY_SYNTH;
}
intptr_t category = effect->dispatcher(effect, effGetPlugCategory, 0, 0, nullptr, 0.0f);

switch (category)
{
case kPlugCategSynth:
return PLUGIN_CATEGORY_SYNTH;
case kPlugCategAnalysis:
return PLUGIN_CATEGORY_UTILITY;
case kPlugCategMastering:
return PLUGIN_CATEGORY_DYNAMICS;
case kPlugCategRoomFx:
return PLUGIN_CATEGORY_DELAY;
case kPlugCategRestoration:
return PLUGIN_CATEGORY_UTILITY;
case kPlugCategGenerator:
return PLUGIN_CATEGORY_SYNTH;
}

if (effect->flags & effFlagsIsSynth)
return PLUGIN_CATEGORY_SYNTH;
if (effect->flags & effFlagsIsSynth)
return PLUGIN_CATEGORY_SYNTH;
}

return getPluginCategoryFromName(m_name);
}
@@ -155,7 +161,7 @@ public:
{
CARLA_ASSERT(effect);

return effect->uniqueID;
return effect ? effect->uniqueID : 0;
}

// -------------------------------------------------------------------
@@ -411,7 +417,6 @@ public:
{
if (gui.type == GUI_EXTERNAL_OSC)
{
#ifndef BUILD_BRIDGE
CARLA_ASSERT(osc.thread);

if (! osc.thread)
@@ -436,7 +441,6 @@ public:
if (! osc.thread->wait(500))
osc.thread->quit();
}
#endif
}
else
{
@@ -490,7 +494,6 @@ public:
deleteBuffers();

uint32_t aIns, aOuts, mIns, mOuts, params, j;
aIns = aOuts = mIns = mOuts = params = 0;

aIns = effect->numInputs;
aOuts = effect->numOutputs;
@@ -498,9 +501,13 @@ public:

if (vstPluginCanDo(effect, "receiveVstEvents") || vstPluginCanDo(effect, "receiveVstMidiEvent") || (effect->flags & effFlagsIsSynth) > 0 || (m_hints & PLUGIN_WANTS_MIDI_INPUT))
mIns = 1;
else
mIns = 0;

if (vstPluginCanDo(effect, "sendVstEvents") || vstPluginCanDo(effect, "sendVstMidiEvent"))
mOuts = 1;
else
mOuts = 0;

if (aIns > 0)
{
@@ -1319,7 +1326,7 @@ public:
bool do_balance = (m_hints & PLUGIN_CAN_BALANCE) > 0 && (x_balanceLeft != -1.0 || x_balanceRight != 1.0);

double bal_rangeL, bal_rangeR;
float bufValue, oldBufLeft[do_balance ? frames : 0];
float bufValue, oldBufLeft[do_balance ? frames : 1];

for (i=0; i < aOut.count; i++)
{
@@ -1460,7 +1467,6 @@ public:
// -------------------------------------------------------------------
// Post-poned events

#ifndef BUILD_BRIDGE
void uiParameterChange(const uint32_t index, const double value)
{
CARLA_ASSERT(index < param.count);
@@ -1512,7 +1518,6 @@ public:
osc_send_midi(&osc.data, midiData);
}
}
#endif

// -------------------------------------------------------------------



+ 1
- 1
c++/carla-utils/carla_lib_utils.hpp View File

@@ -59,7 +59,7 @@ void* lib_symbol(void* const lib, const char* const symbol)
CARLA_ASSERT(lib);
CARLA_ASSERT(symbol);

if (! lib)
if (! (lib && symbol))
return nullptr;

#ifdef Q_OS_WIN


Loading…
Cancel
Save