From 4a043a915f369cc49d40aef4c6d97f2dbab71c5f Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Mon, 10 Nov 2014 17:59:06 +0100 Subject: configure.ac: prepare for 0.18.1 --- NEWS | 2 ++ configure.ac | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/NEWS b/NEWS index 9be75c42e..ed4bbf101 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,5 @@ +ver 0.18.18 (not yet released) + ver 0.18.17 (2014/11/02) * playlist - don't allow empty playlist name diff --git a/configure.ac b/configure.ac index 05a4f5050..ca3d9b24f 100644 --- a/configure.ac +++ b/configure.ac @@ -1,10 +1,10 @@ AC_PREREQ(2.60) -AC_INIT(mpd, 0.18.17, mpd-devel@musicpd.org) +AC_INIT(mpd, 0.18.18, mpd-devel@musicpd.org) VERSION_MAJOR=0 VERSION_MINOR=18 -VERSION_REVISION=17 +VERSION_REVISION=18 VERSION_EXTRA=0 AC_CONFIG_SRCDIR([src/Main.cxx]) -- cgit v1.2.3 From c64ad78c7bfa83585775617c692367e247966330 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Fri, 7 Nov 2014 19:22:26 +0100 Subject: decoder/ffmpeg: support opus --- NEWS | 2 ++ src/decoder/FfmpegDecoderPlugin.cxx | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index ed4bbf101..a9440b844 100644 --- a/NEWS +++ b/NEWS @@ -1,4 +1,6 @@ ver 0.18.18 (not yet released) +* decoder + - ffmpeg: support opus ver 0.18.17 (2014/11/02) * playlist diff --git a/src/decoder/FfmpegDecoderPlugin.cxx b/src/decoder/FfmpegDecoderPlugin.cxx index 104129ad9..69e7a6c8b 100644 --- a/src/decoder/FfmpegDecoderPlugin.cxx +++ b/src/decoder/FfmpegDecoderPlugin.cxx @@ -620,7 +620,7 @@ static const char *const ffmpeg_suffixes[] = { "mj2", "mjpeg", "mjpg", "mka", "mkv", "mlp", "mm", "mmf", "mov", "mp+", "mp1", "mp2", "mp3", "mp4", "mpc", "mpeg", "mpg", "mpga", "mpp", "mpu", "mve", "mvi", "mxf", "nc", "nsv", "nut", "nuv", "oga", "ogm", "ogv", - "ogx", "oma", "ogg", "omg", "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", "sol", "son", "spx", "str", "swf", "tgi", "tgq", "tgv", "thp", "ts", "tsp", "tta", "xa", "xvid", "uv", "uv2", "vb", "vid", "vob", "voc", @@ -654,6 +654,7 @@ static const char *const ffmpeg_mime_types[] = { "audio/mpeg", "audio/musepack", "audio/ogg", + "audio/opus", "audio/qcelp", "audio/vorbis", "audio/vorbis+ogg", -- cgit v1.2.3 From 7e7b403043b55c2e1bb9227fce725ad87626ae97 Mon Sep 17 00:00:00 2001 From: Florent Le Coz Date: Tue, 11 Nov 2014 17:03:29 +0100 Subject: Construct a Null AllocatedPath if the filename conversion into UTF8 failed --- NEWS | 1 + src/fs/AllocatedPath.cxx | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index a9440b844..e1c499860 100644 --- a/NEWS +++ b/NEWS @@ -1,6 +1,7 @@ ver 0.18.18 (not yet released) * decoder - ffmpeg: support opus +* fix crash on failed filename charset conversion ver 0.18.17 (2014/11/02) * playlist diff --git a/src/fs/AllocatedPath.cxx b/src/fs/AllocatedPath.cxx index 37b79a685..4651ea625 100644 --- a/src/fs/AllocatedPath.cxx +++ b/src/fs/AllocatedPath.cxx @@ -46,7 +46,11 @@ AllocatedPath::Build(const_pointer a, const_pointer b) AllocatedPath AllocatedPath::FromUTF8(const char *path_utf8) { - return AllocatedPath(Donate(), ::PathFromUTF8(path_utf8)); + char *path = ::PathFromUTF8(path_utf8); + if (path == nullptr) + return AllocatedPath::Null(); + + return AllocatedPath(Donate(), path); } AllocatedPath -- cgit v1.2.3 From 3f5f96ac91f570a6aa8b73d20f406410d8a79ed4 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Tue, 18 Nov 2014 20:53:59 +0100 Subject: event/ServerSocket: fix get_remote_uid() error value Must return -1 on error, not 0. 0 is root. --- src/event/ServerSocket.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/event/ServerSocket.cxx b/src/event/ServerSocket.cxx index 781d29181..361aba886 100644 --- a/src/event/ServerSocket.cxx +++ b/src/event/ServerSocket.cxx @@ -141,7 +141,7 @@ get_remote_uid(int fd) socklen_t len = sizeof (cred); if (getsockopt(fd, SOL_SOCKET, SO_PEERCRED, &cred, &len) < 0) - return 0; + return -1; return cred.uid; #else -- cgit v1.2.3 From c8b93d6573550ec3735b070245769970db62a312 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Tue, 18 Nov 2014 20:56:27 +0100 Subject: Client: assume uid==0 is local socket A negative uid value means it's not a "local socket" (PF_LOCAL). uid==0 means user "root" connected. --- NEWS | 1 + src/Client.hxx | 2 +- src/ClientFile.cxx | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/NEWS b/NEWS index e1c499860..13f0fe746 100644 --- a/NEWS +++ b/NEWS @@ -2,6 +2,7 @@ ver 0.18.18 (not yet released) * decoder - ffmpeg: support opus * fix crash on failed filename charset conversion +* fix local socket detection from uid=0 (root) ver 0.18.17 (2014/11/02) * playlist diff --git a/src/Client.hxx b/src/Client.hxx index f0bc6b0f7..fd81b59e0 100644 --- a/src/Client.hxx +++ b/src/Client.hxx @@ -109,7 +109,7 @@ public: * a local (UNIX domain) socket? */ bool IsLocal() const { - return uid > 0; + return uid >= 0; } unsigned GetPermission() const { diff --git a/src/ClientFile.cxx b/src/ClientFile.cxx index 382b76083..7a5dd37a6 100644 --- a/src/ClientFile.cxx +++ b/src/ClientFile.cxx @@ -47,7 +47,7 @@ client_allow_file(const Client &client, Path path_fs, Error &error) instance */ return true; - if (uid <= 0) { + if (uid < 0) { /* unauthenticated client */ error.Set(ack_domain, ACK_ERROR_PERMISSION, "Access denied"); return false; -- cgit v1.2.3 From 7aa2104596f283c6af22b7b721267065cda86237 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Tue, 18 Nov 2014 21:34:03 +0100 Subject: release v0.18.18 --- NEWS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 13f0fe746..21b44eec3 100644 --- a/NEWS +++ b/NEWS @@ -1,4 +1,4 @@ -ver 0.18.18 (not yet released) +ver 0.18.18 (2014/11/18) * decoder - ffmpeg: support opus * fix crash on failed filename charset conversion -- cgit v1.2.3