Crash with FrameList

Birunthan Mohanathas poiru at inbox.com
Sun Apr 24 19:34:22 CEST 2011


I seem to have fixed by compiling TagLib along with the project (as opposed to linking TagLib statically).

Sorry for the spam.

> -----Original Message-----
> From: poiru at inbox.com
> Sent: Sun, 24 Apr 2011 07:40:28 -0800
> To: taglib-devel at kde.org
> Subject: Crash with FrameList
> 
> I'm trying to extract the ID3v2 album artwork using TagLib (1.7) on
> Visual Studio 2010. Have been trying to get this to work for several
> hours now, but with no avail. The application always crashes due to the
> FrameList declaration. I've attached the problematic part of the code
> below.
> 
> ---- code ----
> 	TagLib::FileRef ref(filename.c_str());
> 
> 	if (ref.isNull() || !ref.file())
> 		return;
> 
> 	TagLib::MPEG::File* file =
> dynamic_cast<TagLib::MPEG::File*>(ref.file());
> 	if (file && file->ID3v2Tag())
> 	{
> 		// Crash here
> 		TagLib::ID3v2::FrameList apic_frames =
> file->ID3v2Tag()->frameListMap()["APIC"];
> 
> 		if (apic_frames.isEmpty())
> 			return;
> 	}
> ---- end code ----
> 
> >	NowPlaying.dll!std::list<TagLib::ID3v2::Frame
> *,std::allocator<TagLib::ID3v2::Frame *>
> >::_Insert(std::_List_const_iterator<std::_List_val<TagLib::ID3v2::Frame
> *,std::allocator<TagLib::ID3v2::Frame *> > > _Where, TagLib::ID3v2::Frame
> * const & _Val)  Line 975 + 0x3 bytes	C++
> 
> I've been able to use other TagLib methods (e.g. reading ID3v2 tags from
> files), but can't get the above code to work no matter what. I've tested
> with multiple MP3 files with valid ID3v2 tags/artwork.
> 
> Any idea?
> 
> ____________________________________________________________
> TRY FREE IM TOOLPACK at http://www.imtoolpack.com/default.aspx?rc=if5
> Capture screenshots, upload images, edit and send them to your friends
> through IMs, post on Twitter®, Facebook®, MySpace™, LinkedIn® – FAST!
> _______________________________________________
> taglib-devel mailing list
> taglib-devel at kde.org
> https://mail.kde.org/mailman/listinfo/taglib-devel

____________________________________________________________
FREE 3D MARINE AQUARIUM SCREENSAVER - Watch dolphins, sharks & orcas on your desktop!
Check it out at http://www.inbox.com/marineaquarium


More information about the taglib-devel mailing list