From 7eb449dacfbb47f1ae8985786ccd1e612ca4c3c0 Mon Sep 17 00:00:00 2001 From: Orcan Ogetbil Date: Sat, 4 Feb 2012 11:43:20 -0500 Subject: [PATCH] Backported fix for a crash in .ape file parsing RHBZ#700727 --- taglib-ape-id3v2parse.patch | 12 ++++++++++++ taglib.spec | 10 +++++++++- 2 files changed, 21 insertions(+), 1 deletion(-) create mode 100644 taglib-ape-id3v2parse.patch diff --git a/taglib-ape-id3v2parse.patch b/taglib-ape-id3v2parse.patch new file mode 100644 index 0000000..9c58da4 --- /dev/null +++ b/taglib-ape-id3v2parse.patch @@ -0,0 +1,12 @@ +diff -Nur taglib-1.7.orig/taglib/ape/apeproperties.cpp taglib-1.7/taglib/ape/apeproperties.cpp +--- taglib-1.7.orig/taglib/ape/apeproperties.cpp 2011-03-12 00:15:38.000000000 +1100 ++++ taglib-1.7/taglib/ape/apeproperties.cpp 2011-07-29 21:19:45.984345060 +1000 +@@ -137,7 +137,7 @@ + long ID3v2OriginalSize = 0; + bool hasID3v2 = false; + if(ID3v2Location >= 0) { +- ID3v2::Tag tag(d->file, ID3v2Location, 0); ++ ID3v2::Tag tag(d->file, ID3v2Location); + ID3v2OriginalSize = tag.header()->completeTagSize(); + if(tag.header()->tagSize() > 0) + hasID3v2 = true; diff --git a/taglib.spec b/taglib.spec index cf68d5f..268701a 100644 --- a/taglib.spec +++ b/taglib.spec @@ -12,7 +12,7 @@ Name: taglib Version: 1.7 -Release: 2%{?dist} +Release: 3%{?dist} Summary: Audio Meta-Data Library Group: System Environment/Libraries @@ -25,6 +25,10 @@ Source0: http://launchpad.net/taglib/trunk/%{version}%{?pre}/+download/taglib Source1: taglib-svn.sh BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) +# Bugfix: crash parsing ID3v2 tag in ape file due to null +# pointer dereference RHBZ#700727 +# https://bugs.kde.org/show_bug.cgi?id=278773 +Patch0: taglib-ape-id3v2parse.patch # http://bugzilla.redhat.com/343241 # try 1, use pkg-config Patch1: taglib-1.5b1-multilib.patch @@ -80,6 +84,7 @@ Files needed when building software with %{name}. %prep %setup -q -n taglib-%{version}%{?pre} +%patch0 -p1 -b .ape.crash # patch1 not applied ## omit for now %patch2 -p1 -b .multilib @@ -157,6 +162,9 @@ rm -rf %{buildroot} %changelog +* Sat Feb 04 2012 Orcan Ogetbil - 1.7-3 +- Backported fix for a crash in .ape file parsing RHBZ#700727 + * Sat Jan 14 2012 Fedora Release Engineering - 1.7-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild