mirror of
https://github.com/cookiengineer/audacity
synced 2025-08-16 08:34:10 +02:00
Fix crash opening menu in some AU effects
This commit is contained in:
parent
e8ac12160a
commit
7808033421
@ -245,7 +245,7 @@ void AudioUnitEffectsModule::LoadAudioUnitsOfType(OSType inAUType,
|
|||||||
result = AudioComponentGetDescription(component, &found);
|
result = AudioComponentGetDescription(component, &found);
|
||||||
if (result == noErr)
|
if (result == noErr)
|
||||||
{
|
{
|
||||||
CFStringRef cfName;
|
CFStringRef cfName{};
|
||||||
result = AudioComponentCopyName(component, &cfName);
|
result = AudioComponentCopyName(component, &cfName);
|
||||||
CFunique_ptr<const __CFString> uName{ cfName };
|
CFunique_ptr<const __CFString> uName{ cfName };
|
||||||
|
|
||||||
@ -760,7 +760,7 @@ void AudioUnitEffectImportDialog::OnOk(wxCommandEvent & WXUNUSED(evt))
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
CFDataRef xml;
|
CFDataRef xml{};
|
||||||
SInt32 error;
|
SInt32 error;
|
||||||
Boolean res = CFURLCreateDataAndPropertiesFromResource(kCFAllocatorDefault,
|
Boolean res = CFURLCreateDataAndPropertiesFromResource(kCFAllocatorDefault,
|
||||||
url.get(),
|
url.get(),
|
||||||
@ -1673,7 +1673,7 @@ bool AudioUnitEffect::LoadFactoryPreset(int id)
|
|||||||
OSStatus result;
|
OSStatus result;
|
||||||
|
|
||||||
// Retrieve the list of factory presets
|
// Retrieve the list of factory presets
|
||||||
CFArrayRef array;
|
CFArrayRef array{};
|
||||||
UInt32 dataSize = sizeof(CFArrayRef);
|
UInt32 dataSize = sizeof(CFArrayRef);
|
||||||
result = AudioUnitGetProperty(mUnit,
|
result = AudioUnitGetProperty(mUnit,
|
||||||
kAudioUnitProperty_FactoryPresets,
|
kAudioUnitProperty_FactoryPresets,
|
||||||
@ -1724,7 +1724,7 @@ wxArrayString AudioUnitEffect::GetFactoryPresets()
|
|||||||
wxArrayString presets;
|
wxArrayString presets;
|
||||||
|
|
||||||
// Retrieve the list of factory presets
|
// Retrieve the list of factory presets
|
||||||
CFArrayRef array;
|
CFArrayRef array{};
|
||||||
UInt32 dataSize = sizeof(CFArrayRef);
|
UInt32 dataSize = sizeof(CFArrayRef);
|
||||||
result = AudioUnitGetProperty(mUnit,
|
result = AudioUnitGetProperty(mUnit,
|
||||||
kAudioUnitProperty_FactoryPresets,
|
kAudioUnitProperty_FactoryPresets,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user