[audacious-plugins/f15] Fix m3u playlist load corruption (AUDPLUG-380).

Michael Schwendt mschwendt at fedoraproject.org
Sun Jul 3 00:26:02 UTC 2011


commit ba0d61dd5052a8b1b8e5ad5cc41e2965776250ac
Author: Michael Schwendt <mschwendt at fedoraproject.org>
Date:   Sun Jul 3 02:25:45 2011 +0200

    Fix m3u playlist load corruption (AUDPLUG-380).

 audacious-plugins-2.5.2-m3u-eof.patch |   17 ++++++-----------
 audacious-plugins.spec                |    6 +++---
 2 files changed, 9 insertions(+), 14 deletions(-)
---
diff --git a/audacious-plugins-2.5.2-m3u-eof.patch b/audacious-plugins-2.5.2-m3u-eof.patch
index d20da1e..8a3c1ac 100644
--- a/audacious-plugins-2.5.2-m3u-eof.patch
+++ b/audacious-plugins-2.5.2-m3u-eof.patch
@@ -1,18 +1,13 @@
 diff -Nur audacious-plugins-2.5.2-orig/src/m3u/m3u.c audacious-plugins-2.5.2/src/m3u/m3u.c
 --- audacious-plugins-2.5.2-orig/src/m3u/m3u.c	2011-06-20 03:14:25.000000000 +0200
-+++ audacious-plugins-2.5.2/src/m3u/m3u.c	2011-07-03 01:02:42.530825921 +0200
-@@ -51,8 +51,13 @@
++++ audacious-plugins-2.5.2/src/m3u/m3u.c	2011-07-03 02:23:57.591226304 +0200
+@@ -51,6 +51,9 @@
      if (raw == NULL)
          return NULL;
  
--    gchar * text = str_to_utf8 (raw);
-+    gchar * terminated = g_memdup (raw,size+1);
++    raw = g_realloc (raw, size + 1);
++    ((gchar *) raw)[size] = 0;
++
+     gchar * text = str_to_utf8 (raw);
      g_free (raw);
-+    if (terminated == NULL)
-+        return NULL;
-+    terminated[size] = 0;
-+    gchar * text = str_to_utf8 (terminated);
-+    g_free (terminated);
      strip_char (text, '\r');
-     return text;
- }
diff --git a/audacious-plugins.spec b/audacious-plugins.spec
index 0d1e3d9..221f5c2 100644
--- a/audacious-plugins.spec
+++ b/audacious-plugins.spec
@@ -10,7 +10,7 @@ Requires: audacious >= %{aud_ver}
 
 Name: audacious-plugins
 Version: 2.5.2
-Release: 3%{?dist}
+Release: 4%{?dist}
 Summary: Plugins for the Audacious audio player
 Group: Applications/Multimedia
 URL: http://audacious-media-player.org/
@@ -31,7 +31,7 @@ Patch0: audacious-plugins-2.5.2-xmms-skindir.patch
 Patch1: audacious-plugins-2.4-libdir.patch
 # up to git on 20110628
 Patch2: audacious-plugins-2.5.2-git20110628.patch
-# reported, AUDPLUG-380
+# fixed upstream AUDPLUG-380
 Patch3: audacious-plugins-2.5.2-m3u-eof.patch
 
 BuildRequires: audacious-devel >= %{aud_ver}
@@ -273,7 +273,7 @@ update-desktop-database &> /dev/null || :
 
 
 %changelog
-* Sun Jul  3 2011 Michael Schwendt <mschwendt at fedoraproject.org> - 2.5.2-3
+* Sun Jul  3 2011 Michael Schwendt <mschwendt at fedoraproject.org> - 2.5.2-4
 - Fix m3u playlist load corruption (AUDPLUG-380).
 
 * Wed Jun 29 2011 Michael Schwendt <mschwendt at fedoraproject.org> - 2.5.2-2


More information about the scm-commits mailing list