mp3 file making CAAudioFile spin in BasicRead()
mp3 file making CAAudioFile spin in BasicRead()
- Subject: mp3 file making CAAudioFile spin in BasicRead()
- From: Brian Whitman <email@hidden>
- Date: Wed, 14 Dec 2005 01:08:21 -0500
While testing my app (it uses CAAudioFile as a simple "anything to
PCM" converter) on my iTunes library, I found one mp3 file (linked
below) that completely hangs the program. On investigation the same
file hangs any app I could find that uses CAAudioFile during the file-
>open call. It plays fine in iTunes and QT, I don't remember the
provenance of the file but iTunes claims it was encoded with iTunes 4.9.
It's frustrating as I don't want malformed songs to hang my app,
there seems to be no way of getting out of the loop or detecting if
it will happen. Looking a debug trace shows:
CAAudioFile::GetExistingFileInfo
CAAudioFile::InitFileMaxPacketSize
AudioFileProperty
MP3AudioFile::GetProperty
MP3AudioFile::UpdatePacketTable
MP3AudioFile::GetFPosForNextSyncWord
Cached_DataSource::ReadBytes
MacFile_DataSource::ReadBytes
FSReadFork
PBReadForkSync
BasicRead (which spins and eats up all CPU)
How to replicate: build the AudioFileTools.
cd /Developer/Examples/CoreAudio/Services/AudioFileTools/build...
curl -O http://variogr.am/clarity.mp3
./afinfo clarity.mp3
_______________________________________________
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