• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: AudioFileClose() crashing on iOS after playback
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: AudioFileClose() crashing on iOS after playback


  • Subject: Re: AudioFileClose() crashing on iOS after playback
  • From: Brian Willoughby <email@hidden>
  • Date: Sun, 3 Oct 2010 21:25:39 -0700


On Oct 3, 2010, at 21:17, Kyle Sluder wrote:
On Sun, Oct 3, 2010 at 12:39 PM, Roni Music <email@hidden> wrote:
No that's not correct, it should not be retained. The audio file id is valid
until you close the file with AudioFileClose().

If that is the case, then Core Audio is not playing by the Core Foundation memory management rules.


Not really. The audio file object retains the audio file id because it needs it, and releases it during close. However, there is nothing wrong with your code retaining the same audio file id for the duration of time that it needs it, so long as it calls release. This is always the case unless the documentation states otherwise. In other words, if two objects need a reference for some extended period of time, then both should retain it, and then the id will not go away until both are done with it.

I may be speaking out of turn, though, since I have not thoroughly reviewed all of the documentation to see whether there are any special cases here.

Brian Willoughby
Sound Consulting

_______________________________________________
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


  • Follow-Ups:
    • Re: AudioFileClose() crashing on iOS after playback
      • From: Kyle Sluder <email@hidden>
References: 
 >Re: AudioFileClose() crashing on iOS after playback (From: Kyle Sluder <email@hidden>)

  • Prev by Date: Re: AudioFileClose() crashing on iOS after playback
  • Next by Date: Cocoa UI not loading
  • Previous by thread: Re: AudioFileClose() crashing on iOS after playback
  • Next by thread: Re: AudioFileClose() crashing on iOS after playback
  • Index(es):
    • Date
    • Thread