Re: CFRelease issue with preset names
Re: CFRelease issue with preset names
- Subject: Re: CFRelease issue with preset names
- From: William Stewart <email@hidden>
- Date: Mon, 19 Apr 2010 11:02:38 -0700
have a look at the code in AUBase - this handles this property correctly and you should just be using that (walk through it with the PresentPreset property and you'll see how this is handled)
On Apr 18, 2010, at 9:07 AM, contact wrote:
> Hi guys, I'm having an issue with just one host, and I'm a little worried whether my apparent 'fix.'
>
> I'm grabbing a name from my program store using the following in the constructor:
> ('i' is preset loop)
>
> PresetsAU[i].presetName = CFStringCreateWithCString(NULL, pDSP->programData.programs[i].name, kCFStringEncodingISOLatin1 );
>
> In Digital Performer (I don't have it, but someone has informed me) it crashes in the destructor with CFRelease (from the crash log)
> If I remove the following from the destructor...
>
> CFRelease (PresetsAU[i].presetName);
>
> ...then all is fine.
>
> I'm not convinced that it's correct, but it stopped the crashing immediately.
> Is this OK to do?
>
> Cheers,
> Dave
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Coreaudio-api mailing list (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden