@@ -2003,7 +2003,7 @@ private: | |||||
for (LinkedList<const char*>::Itenerator it = sMultiSynthList.begin(); it.valid(); it.next()) | for (LinkedList<const char*>::Itenerator it = sMultiSynthList.begin(); it.valid(); it.next()) | ||||
{ | { | ||||
const char*& itLabel(it.getValue()); | |||||
const char* const itLabel(it.getValue()); | |||||
if (std::strcmp(label, itLabel) == 0) | if (std::strcmp(label, itLabel) == 0) | ||||
return false; | return false; | ||||
@@ -520,13 +520,10 @@ public: | |||||
for (LinkedList<const char*>::Itenerator it = fCustomURIDs.begin(); it.valid(); it.next()) | for (LinkedList<const char*>::Itenerator it = fCustomURIDs.begin(); it.valid(); it.next()) | ||||
{ | { | ||||
const char*& uri(it.getValue()); | |||||
const char* const uri(it.getValue()); | |||||
if (uri != nullptr) | if (uri != nullptr) | ||||
{ | |||||
delete[] uri; | delete[] uri; | ||||
uri = nullptr; | |||||
} | |||||
} | } | ||||
fCustomURIDs.clear(); | fCustomURIDs.clear(); | ||||
@@ -3850,7 +3847,7 @@ public: | |||||
for (size_t i=0; i < fCustomURIDs.count(); ++i) | for (size_t i=0; i < fCustomURIDs.count(); ++i) | ||||
{ | { | ||||
const char*& thisUri(fCustomURIDs.getAt(i)); | |||||
const char* const thisUri(fCustomURIDs.getAt(i)); | |||||
if (thisUri != nullptr && std::strcmp(thisUri, uri) == 0) | if (thisUri != nullptr && std::strcmp(thisUri, uri) == 0) | ||||
return static_cast<LV2_URID>(i); | return static_cast<LV2_URID>(i); | ||||
} | } | ||||
@@ -327,13 +327,10 @@ public: | |||||
for (LinkedList<const char*>::Itenerator it = fCustomURIDs.begin(); it.valid(); it.next()) | for (LinkedList<const char*>::Itenerator it = fCustomURIDs.begin(); it.valid(); it.next()) | ||||
{ | { | ||||
const char*& uri(it.getValue()); | |||||
const char* const uri(it.getValue()); | |||||
if (uri != nullptr) | if (uri != nullptr) | ||||
{ | |||||
delete[] uri; | delete[] uri; | ||||
uri = nullptr; | |||||
} | |||||
} | } | ||||
fCustomURIDs.clear(); | fCustomURIDs.clear(); | ||||
@@ -566,7 +563,7 @@ public: | |||||
for (size_t i=0; i < fCustomURIDs.count(); ++i) | for (size_t i=0; i < fCustomURIDs.count(); ++i) | ||||
{ | { | ||||
const char*& thisUri(fCustomURIDs.getAt(i)); | |||||
const char* const thisUri(fCustomURIDs.getAt(i)); | |||||
if (thisUri != nullptr && std::strcmp(thisUri, uri) == 0) | if (thisUri != nullptr && std::strcmp(thisUri, uri) == 0) | ||||
return i; | return i; | ||||
} | } | ||||
@@ -176,7 +176,7 @@ public: | |||||
if (index >= fPrograms.count()) | if (index >= fPrograms.count()) | ||||
return nullptr; | return nullptr; | ||||
const ProgramInfo*& pInfo(fPrograms.getAt(index)); | |||||
const ProgramInfo* const pInfo(fPrograms.getAt(index)); | |||||
fRetProgram.bank = pInfo->bank; | fRetProgram.bank = pInfo->bank; | ||||
fRetProgram.program = pInfo->prog; | fRetProgram.program = pInfo->prog; | ||||
@@ -59,7 +59,7 @@ struct PluginListManager { | |||||
#ifdef CARLA_NATIVE_PLUGIN_LV2 | #ifdef CARLA_NATIVE_PLUGIN_LV2 | ||||
for (LinkedList<const LV2_Descriptor*>::Itenerator it = lv2Descs.begin(); it.valid(); it.next()) | for (LinkedList<const LV2_Descriptor*>::Itenerator it = lv2Descs.begin(); it.valid(); it.next()) | ||||
{ | { | ||||
const LV2_Descriptor*& lv2Desc(it.getValue()); | |||||
const LV2_Descriptor* const lv2Desc(it.getValue()); | |||||
delete[] lv2Desc->URI; | delete[] lv2Desc->URI; | ||||
delete lv2Desc; | delete lv2Desc; | ||||
} | } | ||||
@@ -1399,7 +1399,7 @@ const LV2_Descriptor* lv2_descriptor(uint32_t index) | |||||
return plm.lv2Descs.getAt(index); | return plm.lv2Descs.getAt(index); | ||||
} | } | ||||
const NativePluginDescriptor*& pluginDesc(plm.descs.getAt(index)); | |||||
const NativePluginDescriptor* const pluginDesc(plm.descs.getAt(index)); | |||||
CarlaString tmpURI; | CarlaString tmpURI; | ||||