Compare commits

..

15 Commits

Author SHA1 Message Date
Max Kellermann
79f2f8cddc release v0.19.13 2016-02-23 22:06:13 +01:00
Max Kellermann
39fa949345 queue/Playlist: move only the tag items in TagModified()
Fixes disappearing duration of remote songs during playback.

See http://bugs.musicpd.org/view.php?id=4492
2016-02-23 21:01:55 +01:00
Max Kellermann
e1d7a5cbf5 DetachedSong: add method MoveTagItemsFrom() 2016-02-23 20:59:44 +01:00
Max Kellermann
f3cefaf043 tag/Tag: move code to MoveItemsFrom() 2016-02-23 20:57:56 +01:00
Max Kellermann
b3460f3f54 configure.ac, unix/Daemon: check for initgroups() at configure time
The initgroups() manpage says we need to check for _BSD_SOURCE.  The
thing is that glibc deprecated this macro, and doesn't define it
anymore, effectively breaking all MPD supplementary groups.

The real fix is to check for initgroups() availability at configure
time, instead of relying on the deprecated _BSD_SOURCE macro.
2016-02-23 20:13:34 +01:00
Chris Spiegel
1e0ad1f6bf Add TAK as a supported FFmpeg format. 2016-02-19 17:32:48 +01:00
Max Kellermann
4abcb08cc9 tag/{aiff,riff}: fix ID3 chunk padding
Apply padding only to the fseek(), not to the chunk size.  This fixes
bogus "failed to read riff chunk" messages when the last chunk has an
odd size.

See http://bugs.musicpd.org/view.php?id=4486
2016-02-19 17:31:20 +01:00
Max Kellermann
81e7833711 configure.ac: prepare for 0.19.13 2016-02-19 17:30:01 +01:00
Max Kellermann
82e261ad33 release v0.19.12 2015-12-15 21:54:42 +01:00
Benno Fünfstück
cae2811762 fix mpd crash on invalid utf8 stream title 2015-12-15 21:49:53 +01:00
Ben Boeckel
09112c6869 docs: add vlc and mpv to the list of example applications
These are other popular clients. In particular, VLC is available on
mobile devices.

Signed-off-by: Ben Boeckel <mathstuf@gmail.com>
2015-12-15 21:30:26 +01:00
Christian Hesse
77aaf1baee fix LimitRTTIME in systemd unit file
systemd does not understand LimitRTTIME=-1. For no limit we have to use
the string 'infinity' (see systemd.exec(5)).

Signed-off-by: Christian Hesse <mail@eworm.de>
2015-12-15 21:17:04 +01:00
Jörg Krause
6626c2d00d Makefile.am: fix static build with alsa
Add ALSA_LIBS to MIXER_LIBS, otherwise building mpd in a static context fails
with lot of undefined references to alsa-lib (libasound) required by
src/mixer/plugins/AlsaMixerPlugin.cxx.

Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
2015-12-15 21:16:45 +01:00
Michael Paquier
315f9d98f6 Main: fix build failure on non-Linux systems 2015-11-10 08:38:53 +01:00
Max Kellermann
f087518e7a configure.ac: prepare for 0.19.12 2015-11-10 08:33:50 +01:00
14 changed files with 50 additions and 18 deletions

View File

@@ -1219,6 +1219,7 @@ liboutput_plugins_a_SOURCES = \
MIXER_LIBS = \ MIXER_LIBS = \
libmixer_plugins.a \ libmixer_plugins.a \
$(ALSA_LIBS) \
$(PULSE_LIBS) $(PULSE_LIBS)
MIXER_API_SRC = \ MIXER_API_SRC = \

13
NEWS
View File

@@ -1,3 +1,16 @@
ver 0.19.13 (2016/02/23)
* tags
- aiff, riff: fix ID3 chunk padding
* decoder
- ffmpeg: support the TAK codec
* fix disappearing duration of remote songs during playback
* initialize supplementary groups with glibc 2.19+
ver 0.19.12 (2015/12/15)
* fix assertion failure on malformed UTF-8 tag
* fix build failure on non-Linux systems
* fix LimitRTTIME in systemd unit file
ver 0.19.11 (2015/10/27) ver 0.19.11 (2015/10/27)
* tags * tags
- ape: fix buffer overflow - ape: fix buffer overflow

View File

@@ -1,10 +1,10 @@
AC_PREREQ(2.60) AC_PREREQ(2.60)
AC_INIT(mpd, 0.19.11, musicpd-dev-team@lists.sourceforge.net) AC_INIT(mpd, 0.19.13, musicpd-dev-team@lists.sourceforge.net)
VERSION_MAJOR=0 VERSION_MAJOR=0
VERSION_MINOR=19 VERSION_MINOR=19
VERSION_REVISION=11 VERSION_REVISION=13
VERSION_EXTRA=0 VERSION_EXTRA=0
AC_CONFIG_SRCDIR([src/Main.cxx]) AC_CONFIG_SRCDIR([src/Main.cxx])
@@ -206,6 +206,7 @@ if test x$host_is_linux = xyes; then
fi fi
AC_CHECK_FUNCS(getpwnam_r getpwuid_r) AC_CHECK_FUNCS(getpwnam_r getpwuid_r)
AC_CHECK_FUNCS(initgroups)
AC_CHECK_FUNCS(strndup) AC_CHECK_FUNCS(strndup)
if test x$host_is_linux = xyes; then if test x$host_is_linux = xyes; then

View File

@@ -2647,7 +2647,8 @@ buffer_size: 16384</programlisting>
/ <ulink / <ulink
url="http://icecast.org/"><application>IceCast</application></ulink>. url="http://icecast.org/"><application>IceCast</application></ulink>.
HTTP streaming clients like HTTP streaming clients like
<application>mplayer</application> can connect to it. <application>mplayer</application>, <application>VLC</application>,
and <application>mpv</application> can connect to it.
</para> </para>
<para> <para>

View File

@@ -188,6 +188,14 @@ public:
tag = std::move(other.tag); tag = std::move(other.tag);
} }
/**
* Similar to the MoveTagFrom(), but move only the #TagItem
* array.
*/
void MoveTagItemsFrom(DetachedSong &&other) {
tag.MoveItemsFrom(std::move(other.tag));
}
time_t GetLastModified() const { time_t GetLastModified() const {
return mtime; return mtime;
} }

View File

@@ -630,7 +630,7 @@ static int mpd_main_after_fork(struct options options)
config_get_unsigned(CONF_AUTO_UPDATE_DEPTH, config_get_unsigned(CONF_AUTO_UPDATE_DEPTH,
INT_MAX)); INT_MAX));
#else #else
FormatWarning(main_domain, FormatWarning(config_domain,
"inotify: auto_update was disabled. enable during compilation phase"); "inotify: auto_update was disabled. enable during compilation phase");
#endif #endif
} }

View File

@@ -738,7 +738,7 @@ static const char *const ffmpeg_suffixes[] = {
"mve", "mvi", "mxf", "nc", "nsv", "nut", "nuv", "oga", "ogm", "ogv", "mve", "mvi", "mxf", "nc", "nsv", "nut", "nuv", "oga", "ogm", "ogv",
"ogx", "oma", "ogg", "omg", "opus", "psp", "pva", "qcp", "qt", "r3d", "ra", "ogx", "oma", "ogg", "omg", "opus", "psp", "pva", "qcp", "qt", "r3d", "ra",
"ram", "rl2", "rm", "rmvb", "roq", "rpl", "rvc", "shn", "smk", "snd", "ram", "rl2", "rm", "rmvb", "roq", "rpl", "rvc", "shn", "smk", "snd",
"sol", "son", "spx", "str", "swf", "tgi", "tgq", "tgv", "thp", "ts", "sol", "son", "spx", "str", "swf", "tak", "tgi", "tgq", "tgv", "thp", "ts",
"tsp", "tta", "xa", "xvid", "uv", "uv2", "vb", "vid", "vob", "voc", "tsp", "tta", "xa", "xvid", "uv", "uv2", "vb", "vid", "vob", "voc",
"vp6", "vmd", "wav", "webm", "wma", "wmv", "wsaud", "wsvga", "wv", "vp6", "vmd", "wav", "webm", "wma", "wmv", "wsaud", "wsvga", "wv",
"wve", "wve",

View File

@@ -37,7 +37,7 @@ playlist::TagModified(DetachedSong &&song)
DetachedSong &current_song = queue.GetOrder(current); DetachedSong &current_song = queue.GetOrder(current);
if (song.IsSame(current_song)) if (song.IsSame(current_song))
current_song.MoveTagFrom(std::move(song)); current_song.MoveTagItemsFrom(std::move(song));
queue.ModifyAtOrder(current); queue.ModifyAtOrder(current);
queue.IncrementVersion(); queue.IncrementVersion();

View File

@@ -84,14 +84,14 @@ aiff_seek_id3(FILE *file)
underflow when casting to off_t */ underflow when casting to off_t */
return 0; return 0;
if (size % 2 != 0)
/* pad byte */
++size;
if (memcmp(chunk.id, "ID3 ", 4) == 0) if (memcmp(chunk.id, "ID3 ", 4) == 0)
/* found it! */ /* found it! */
return size; return size;
if (size % 2 != 0)
/* pad byte */
++size;
if (fseek(file, size, SEEK_CUR) != 0) if (fseek(file, size, SEEK_CUR) != 0)
return 0; return 0;
} }

View File

@@ -82,15 +82,15 @@ riff_seek_id3(FILE *file)
underflow when casting to off_t */ underflow when casting to off_t */
return 0; return 0;
if (size % 2 != 0)
/* pad byte */
++size;
if (memcmp(chunk.id, "id3 ", 4) == 0 || if (memcmp(chunk.id, "id3 ", 4) == 0 ||
memcmp(chunk.id, "ID3 ", 4) == 0) memcmp(chunk.id, "ID3 ", 4) == 0)
/* found it! */ /* found it! */
return size; return size;
if (size % 2 != 0)
/* pad byte */
++size;
if (fseek(file, size, SEEK_CUR) != 0) if (fseek(file, size, SEEK_CUR) != 0)
return 0; return 0;
} }

View File

@@ -80,9 +80,17 @@ struct Tag {
Tag &operator=(Tag &&other) { Tag &operator=(Tag &&other) {
duration = other.duration; duration = other.duration;
has_playlist = other.has_playlist; has_playlist = other.has_playlist;
MoveItemsFrom(std::move(other));
return *this;
}
/**
* Similar to the move operator, but move only the #TagItem
* array.
*/
void MoveItemsFrom(Tag &&other) {
std::swap(items, other.items); std::swap(items, other.items);
std::swap(num_items, other.num_items); std::swap(num_items, other.num_items);
return *this;
} }
/** /**

View File

@@ -40,9 +40,9 @@ FindInvalidUTF8(const char *p, const char *const end)
/* now call the other SequenceLengthUTF8() overload /* now call the other SequenceLengthUTF8() overload
which also validates the continuations */ which also validates the continuations */
const size_t t = SequenceLengthUTF8(p); const size_t t = SequenceLengthUTF8(p);
assert(s == t);
if (t == 0) if (t == 0)
return p; return p;
assert(s == t);
p += s; p += s;
} }

View File

@@ -110,7 +110,7 @@ daemonize_set_user(void)
(int)user_gid); (int)user_gid);
} }
#ifdef _BSD_SOURCE #ifdef HAVE_INITGROUPS
/* init supplementary groups /* init supplementary groups
* (must be done before we change our uid) * (must be done before we change our uid)
*/ */

View File

@@ -7,7 +7,7 @@ ExecStart=@prefix@/bin/mpd --no-daemon
# allow MPD to use real-time priority 50 # allow MPD to use real-time priority 50
LimitRTPRIO=50 LimitRTPRIO=50
LimitRTTIME=-1 LimitRTTIME=infinity
[Install] [Install]
WantedBy=multi-user.target WantedBy=multi-user.target