diff --git a/.gitignore b/.gitignore index 14d65c4..319953a 100644 --- a/.gitignore +++ b/.gitignore @@ -8,3 +8,4 @@ /audacious-3.3-beta2.tar.bz2 /audacious-3.3.tar.bz2 /audacious-3.3.1.tar.bz2 +/audacious-3.3.2.tar.bz2 diff --git a/audacious-3.3.2-urls.patch b/audacious-3.3.2-urls.patch new file mode 100644 index 0000000..95c3a96 --- /dev/null +++ b/audacious-3.3.2-urls.patch @@ -0,0 +1,98 @@ +diff -Nurb --strip-trailing-cr /tmp/tmp.0ZS0jd1PFt/audacious-old/src/audacious/playlist-files.c audacious/src/audacious/playlist-files.c +--- /tmp/tmp.0ZS0jd1PFt/audacious-old/src/audacious/playlist-files.c 2012-01-29 11:00:03.000000000 +0100 ++++ audacious/src/audacious/playlist-files.c 2012-09-24 11:00:05.546346058 +0200 +@@ -28,23 +28,23 @@ + #include "plugin.h" + #include "plugins.h" + +-static const char * get_extension (const char * filename) ++static PluginHandle * get_plugin_silent (const char * filename) + { +- const char * ext; +- uri_parse (filename, NULL, & ext, NULL, NULL); +- return (ext && ext[0] == '.') ? ext + 1 : NULL; ++ char buf[32]; ++ if (! uri_get_extension (filename, buf, sizeof buf)) ++ return NULL; ++ ++ return playlist_plugin_for_extension (buf); + } + + bool_t filename_is_playlist (const char * filename) + { +- const char * ext = get_extension (filename); +- return (ext && playlist_plugin_for_extension (ext)) ? TRUE : FALSE; ++ return (get_plugin_silent (filename) != NULL); + } + + static PluginHandle * get_plugin (const char * filename, bool_t saving) + { +- const char * ext = get_extension (filename); +- PluginHandle * plugin = ext ? playlist_plugin_for_extension (ext) : NULL; ++ PluginHandle * plugin = get_plugin_silent (filename); + + if (! plugin) + { +diff -Nurb --strip-trailing-cr /tmp/tmp.0ZS0jd1PFt/audacious-old/src/audacious/probe.c audacious/src/audacious/probe.c +--- /tmp/tmp.0ZS0jd1PFt/audacious-old/src/audacious/probe.c 2012-01-29 11:00:03.000000000 +0100 ++++ audacious/src/audacious/probe.c 2012-09-24 11:00:05.546346058 +0200 +@@ -130,17 +130,11 @@ + + static void probe_by_extension (ProbeState * state) + { +- const char * ext, * sub; +- uri_parse (state->filename, NULL, & ext, & sub, NULL); +- +- if (ext == sub) ++ char buf[32]; ++ if (! uri_get_extension (state->filename, buf, sizeof buf)) + return; + + AUDDBG ("Probing by extension.\n"); +- char buf[sub - ext]; +- memcpy (buf, ext + 1, sub - ext - 1); +- buf[sub - ext - 1] = 0; +- + input_plugin_for_key (INPUT_KEY_EXTENSION, buf, (PluginForEachFunc) probe_func_fast, state); + } + +diff -Nurb --strip-trailing-cr /tmp/tmp.0ZS0jd1PFt/audacious-old/src/libaudcore/audstrings.c audacious/src/libaudcore/audstrings.c +--- /tmp/tmp.0ZS0jd1PFt/audacious-old/src/libaudcore/audstrings.c 2012-06-04 11:00:03.000000000 +0200 ++++ audacious/src/libaudcore/audstrings.c 2012-09-24 11:00:05.546346058 +0200 +@@ -253,6 +253,24 @@ + * isub_p = isub; + } + ++EXPORT bool_t uri_get_extension (const char * uri, char * buf, int buflen) ++{ ++ const char * ext; ++ uri_parse (uri, NULL, & ext, NULL, NULL); ++ ++ if (ext[0] != '.') ++ return FALSE; ++ ++ g_strlcpy (buf, ext + 1, buflen); ++ ++ /* remove subtunes and HTTP query strings */ ++ char * qmark; ++ if ((qmark = strchr (buf, '?'))) ++ * qmark = 0; ++ ++ return (buf[0] != 0); ++} ++ + /* Like strcasecmp, but orders numbers correctly (2 before 10). */ + /* Non-ASCII characters are treated exactly as is. */ + /* Handles NULL gracefully. */ +diff -Nurb --strip-trailing-cr /tmp/tmp.0ZS0jd1PFt/audacious-old/src/libaudcore/audstrings.h audacious/src/libaudcore/audstrings.h +--- /tmp/tmp.0ZS0jd1PFt/audacious-old/src/libaudcore/audstrings.h 2012-06-04 11:00:03.000000000 +0200 ++++ audacious/src/libaudcore/audstrings.h 2012-09-24 11:00:05.546346058 +0200 +@@ -42,6 +42,7 @@ + + void uri_parse (const char * uri, const char * * base_p, const char * * ext_p, + const char * * sub_p, int * isub_p); ++bool_t uri_get_extension (const char * uri, char * buf, int buflen); + + int string_compare (const char * a, const char * b); + int string_compare_encoded (const char * a, const char * b); + diff --git a/audacious.spec b/audacious.spec index 1366911..bf1acd6 100644 --- a/audacious.spec +++ b/audacious.spec @@ -7,7 +7,7 @@ Name: audacious -Version: 3.3.1 +Version: 3.3.2 Release: 1%{?dist} License: BSD @@ -17,6 +17,9 @@ Group: Applications/Multimedia Source0: http://distfiles.audacious-media-player.org/audacious-%{tar_ver}.tar.bz2 +# from devel +Patch0: audacious-3.3.2-urls.patch + BuildRequires: gettext BuildRequires: gtk3-devel BuildRequires: libguess-devel >= 1.1 @@ -81,6 +84,7 @@ Files needed when building software for the Audacious audio player. %prep %setup -q -n %{name}-%{tar_ver} +%patch0 -p1 -b .urls-strip # Verify the value of the audacious(plugin-api) Provides. api=$(grep '[ ]*#define[ ]*_AUD_PLUGIN_VERSION[ ]\+' src/audacious/plugin.h | sed 's!.*_AUD_PLUGIN_VERSION[ ]*\([0-9]\+\).*!\1!') @@ -165,6 +169,10 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : %changelog +* Mon Sep 24 2012 Michael Schwendt - 3.3.2-1 +- Update to 3.3.2 (a few bug-fixes and translation updates). +- Merge content detection fix for URLs that contain parameters. + * Mon Aug 13 2012 Michael Schwendt - 3.3.1-1 - Update to 3.3.1 (a few bug-fixes and translation updates). diff --git a/sources b/sources index cbfd93b..b8ae5c1 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -06a11023fcbcdfe07d2232d8340fb61e audacious-3.3.1.tar.bz2 +21a72e085d1b26341eab20e1dd7257d8 audacious-3.3.2.tar.bz2