Commit Graph

1453 Commits

Author SHA1 Message Date
Max Kellermann 2eef4e6716 thread/Thread: add debug attribute "inside_handle"
This attribute shall be used only for IsInside() to make this safe
against a race condition described in #188:

> There is no requirement on the implementation that the ID of the
> created thread be available before the newly created thread starts
> executing.

http://pubs.opengroup.org/onlinepubs/009695399/functions/pthread_create.html):

This means that on some pthread implementations (e.g. Haiku), the
assert(thread.IsInside()) could fail.

Closes #188
2018-01-08 09:58:18 +01:00
Max Kellermann 34eef0ed84 Merge branch 'v0.20.x' 2018-01-07 17:24:05 +01:00
Max Kellermann 0ef553d30e increment version number to 0.20.16 2018-01-06 13:15:47 +01:00
Max Kellermann c74e018359 Merge branch 'v0.20.x' 2018-01-05 18:11:04 +01:00
Max Kellermann ed4d0aa909 release v0.20.15 2018-01-05 17:55:25 +01:00
Max Kellermann cab77e35e0 queue/PlaylistControl: fix crash after seek failure
This completes the bug fix commit
2065e3290452377b2931f3129b230c8cc536cbc8; if we clear "queued" then we
must clear "queued_song" as well, or another variant of the assertion
fails.
2018-01-05 13:00:24 +01:00
Max Kellermann 4a120f8090 Merge branch 'v0.20.x' 2018-01-05 10:10:17 +01:00
Max Kellermann 329f9cd9fe thread/Util: no ioprio_set() on Android due to seccomp/SIGSYS 2018-01-04 19:33:14 +01:00
Felix Hädicke fbdb8b406e Makefile.am: build Android APK package without Ant
In current Android SDK releases, Ant support was removed. Move the
necessary build steps from the former Ant build system to our Makefile,
and call the required build tools from the Android SDK (aapt and dx),
Java SDK (javac) and Info-ZIP (zip) directly.

[mk: copied from Felix's commit
e52b906dba971a1173f9e8f83d32b52ee9f89af3 in the XCSoar project)
2018-01-04 18:55:54 +01:00
Max Kellermann 1954e94de2 Merge branch 'work_tag' of git://github.com/loujine/MPD
Closes #181
2018-01-03 11:47:02 +01:00
Max Kellermann f6ec43b9ec pcm/Resampler: add virtual method Flush()
Wired to Filter::Flush().

Closes #153
2018-01-02 23:17:25 +01:00
Max Kellermann c68ed40661 pcm/SoxrResampler: implement method Reset() 2018-01-02 21:53:09 +01:00
Max Kellermann 67a8eedca0 output/ao: round write_size down to a multiple of the frame size 2018-01-02 17:33:33 +01:00
Max Kellermann 28c5e7e6a7 Merge branch 'v0.20.x' 2018-01-02 14:16:47 +01:00
Max Kellermann ff624075a8 storage/State: check if a CompositeStorage exists; fixes nullptr dereference
Fixes another crash bug caused by commit
64d141f71e
2018-01-02 14:13:26 +01:00
Max Kellermann ff6b263b48 increment version number to 0.20.15 2018-01-02 13:46:03 +01:00
Max Kellermann 5227582e90 release v0.20.14
-----BEGIN PGP SIGNATURE-----
 
 iQJEBAABCAAuFiEEA5IzWngIOJSkMBxDI26KWMbbRRIFAlpKaAoQHG1heEBtdXNp
 Y3BkLm9yZwAKCRAjbopYxttFEpI/D/9ZjsoVxvRn+09rq4Aczzy98HchovhGVhrA
 iqUp6xpBk5/nw53GBBxanLnRbPyjrtH0KDb3aRFrPM2ujYwD8cYCspcEF73Uy9rW
 rtjock3/EJrS2WgoBBp82f41YIwqjI6LUreASfhU1+ySE3G8aeDHQkouvpzh3GzT
 cND0ZJYijRFNWTA6mW7ebAtwtclxxQDYgXaxAQH/lX7uVijGtndhSUyE2I6VnrJW
 VtiZLPInPPqaq+sbZ8L8D1VuswNKkF3z3JNSe9V1003IopMZrte56HdjMqJzqMhS
 medA++d8771N0nFsbj656D0VHMoUMdq63xPGG7VulHuW1ZeDMWo2T/gASkz5e+mh
 yEdJYFsOV44B9brDJsPtA4r8dnWlWvKsP/Jak/ozVvjQ/xvixJnmg32OdcSXqou5
 SS3VQnkiPIOXdCB5VqRutfQMNwyj/TRMV6WLDG+MBwAabRjPX+6tZL9C3knJHsz5
 z+9UQrYuwPfWwjrB+T5/FvDZ6DdOy9QK8KzMfvyK3fzajCm/3asVkArvNnqQ4Qen
 ZkRGNfsVRQC5E+ZZoRmg+OZDi+jxBc9PY7TUhlDZU1sW5OP9HG0zowtJdOExTU+m
 5J7gEPvZxjiQmdWszaJC7eFntd4iaN+zDEXZTJCg65HWYUjjMwcFFPhGE9lrQ8wN
 WdT6o86fcQ==
 =0AWT
 -----END PGP SIGNATURE-----

Merge tag 'v0.20.14'

release v0.20.14
2018-01-01 18:28:39 +01:00
Max Kellermann c0bf052fa9 release v0.20.14 2018-01-01 17:55:38 +01:00
Max Kellermann 7384ec199e Compiler.h: remove support for GCC 4.9
Supporting GCC 4.9 is becoming cumbersome as we refactor more code to
C++14.

This shouldn't be a problem for anybody, because Debian Stable
(Stretch) has version 6.3, and Ubuntu LTS (Xenial) has version 5.3.
2017-12-27 08:40:24 +01:00
Max Kellermann 300a619991 Merge branch 'v0.20.x' 2017-12-22 16:10:05 +01:00
Max Kellermann d094c168aa archive/{iso9660,zzip}: unlock the mutex during I/O
Similar to commit 31ab78ae8e
2017-12-22 16:09:03 +01:00
Max Kellermann 4b18460bc6 archive/bz2: unlock the archive mutex and lock the file mutex
Fixes deadlock because FileInputStream::Read() unlocks the mutex
(which was not locked) and then locks it, keeping it locked.  This can
result in a deadlock.  This happens because the archive and the file
mutex are different.
2017-12-22 16:02:23 +01:00
Ilya ilyxa Tyshchenko 2becf79223 correct action for compile on Solaris 11.3 X86 2017-12-21 18:42:36 +01:00
Max Kellermann ad1d5e8248 Merge branch 'v0.20.x' 2017-12-21 10:25:28 +01:00
Max Kellermann c88056ba83 db/simple: fix file corruption in the presence of mount points
If a directory is a mount point, omit the "directory: " as well.

This bug is years old, but has become more visible now that mount
points are persistent in the state file.
2017-12-21 10:16:52 +01:00
Max Kellermann e769751221 increment version number to 0.20.14 2017-12-21 10:15:16 +01:00
Max Kellermann 8ac73a9eba output/alsa: add attributes "dop" and "allowed_formats" 2017-12-19 11:57:52 +01:00
Max Kellermann 86a06a7acc output/Interface: add "attributes" map
These attributes are printed in the "outputs" response, and the new
command "outputset" allows setting new values.

No attributes are currently implemented.
2017-12-19 11:57:52 +01:00
Max Kellermann 39dc83bd82 output/Print: print the plugin name 2017-12-19 11:52:10 +01:00
Max Kellermann b9659ba0c0 release v0.20.13
-----BEGIN PGP SIGNATURE-----
 
 iQJEBAABCAAuFiEEA5IzWngIOJSkMBxDI26KWMbbRRIFAlo4RDQQHG1heEBtdXNp
 Y3BkLm9yZwAKCRAjbopYxttFEpm6EACTPaPwGbxS770jJ74vLGSltnZTohaKbRvp
 rIaJGkHTTzPlvw8dpLHmave9fL5ODSchTBmIHqb0loM9011oJgvXUKq3fqEQJUUW
 eFZ54emSDXOjholsd8ykJgrPjMBO2UNEk5T/r6bZdNZlLAN7yNOXkJHezPY8qyzA
 s07o9jmFEKjyLOsMlmEaV2uiCZ9UhPUSUI+vy+Q7qwwil24AfOzXc4+gAB3bV87E
 FFWWP8KO83X2ZrhPZdSeILFcI0i93X/l0rskvf4bgHtoegaYPWk/KnhPnmJ2DC48
 GFzigB5ZbU+OGXz1We7O6DZg6KOB4Y6dDPThtxS0rBTZWCPM6biDVsDFexqACf8u
 sCYTzaTlvAV2gHVGp3csVwXS9gqxYOZbiyMgyMOVKygrvuhgrnQydZQW8yweoscP
 tRxVcKfHclbdsEJHboT1Tp4ibh4+iIT48muMpLDlX6h0KC4OOTSg8m3UGV6V4UAA
 bkDVueFYQcr1tyENJbFGRt6gCENY7rdJMX30TvC0DhDtHXUwY6O5G//w5iqpeztv
 svcOuQQURxmPcFuvIqpTpcX0bSEuYkCt9JF31xzFbvmUhB1bb4sZ+IMvBqS9fnUH
 HJmDLLl7mppX3hlPDc9wLc3Dmpfr5Cd1GLO0CkWhnE8KBONV1auYXh8Gtwdsa/Rv
 idA/53WlvQ==
 =+PRl
 -----END PGP SIGNATURE-----

Merge tag 'v0.20.13'

release v0.20.13
2017-12-18 23:48:14 +01:00
Max Kellermann 49b9a90c3f release v0.20.13 2017-12-18 23:41:56 +01:00
FlashSystems 64d141f71e Save and restore mountpoints within the state file.
Signed-off-by: FlashSystems <developer@flashsystems.de>
2017-12-18 23:39:01 +01:00
FlashSystems c488d3123f Fix `lsinfo` and `add` for mounted databases.
If `SimpleDatabase::Visit` is called on a database that contains a mounted directry the URIs of the elements passed to the callbacks are not prefixed by the mountpoint path. This leads to lsinfo and add not working because they use the wrong URI. This pull request is using the `WalkMount` helper function to create prefixed versions of `VisitDirectory`, `VisitSong` and `VisitPlaylist` to add the correct prefix to the parameters of the callback functions.
2017-12-18 23:33:08 +01:00
Stefano Miccoli 967af60327 rounds alsa HW mixer volume towards ±∞ depending on sgn(∆ vol)
This alleviates a problem in which 'volume +1' cannot be undo by
'volume -1' when using alsa hw mixer.

Closes #104
2017-12-18 21:29:03 +01:00
Max Kellermann 6246d36fe6 Merge branch 'v0.20.x' 2017-12-16 20:56:06 +01:00
Yue Wang f1ef9f9d31 OSXOutputPlugin: set the buffer time to be 100ms
[mk: the following text was copied from
https://github.com/MusicPlayerDaemon/MPD/pull/167]

For certain format (hi-res files) and normal buffer size hardware, The
hardware may at once consume most of the buffers. However, in Delay()
function, MPD is supposed to wait for 25 ms after the next try. it
will create a hiccup. The negative impact is much major than
increasing the latency.

I understand larger buffers come at a price. That's why in my earlier
commit last year I significantly reduced it. However, the buffer size
in CoreAudio is set according to the hardware, which is super small
latency. For instance, the system audio of 2015 generation of macbook
pro has maximum buffer size of 4096 samples, which is just 0.09s for
44.1k framerate, or 0.04s for 96k frames --- . compare to the 0.5 sec
latency alsa plugin has, even if we quadruple it, it's still super
tiny.
2017-12-12 10:56:42 +01:00
Max Kellermann dfaf08743c *: check defined(_WIN32) instead of defined(WIN32)
Only _WIN32 is defined by the compiler, and WIN32 is not standardized
and may be missing.

Closes #169
2017-12-12 10:22:20 +01:00
Max Kellermann 75d068b7cd Makefile.am: include Windows cross-build script in source tarball 2017-12-05 11:24:52 +01:00
Max Kellermann fbc4bb29dc Merge branch 'v0.20.x' 2017-12-03 16:22:08 +01:00
FlashSystems 1208503888 Removing gcc_malloc attribute from `Directory::CreateChild` to fix
assignment of `mnt->mounted_database` in `SimpleDatabase::Mount`.
2017-12-03 12:34:08 +01:00
Max Kellermann 478180ebe4 queue/PlaylistEdit: shuffle appended songs only within its priority group
Fixes #165.
2017-12-02 17:17:02 +01:00
Max Kellermann 78728138a0 lib/upnp/Compat: disable the 1.8 API emulation with libupnp 1.6.24
libupnp 1.6.24 added a few badly designed macros which break the MPD
build:

 8177a4195a/

To work around this, we disable our emulation functions (from
714011c81e) on this libupnp version.

Closes #163
2017-12-02 14:47:27 +01:00
FlashSystems 63fc98591d Fix for "Mount-Points are purged from database on update/rescan."
Signed-off-by: FlashSystems <developer@flashsystems.de>
2017-11-27 22:34:49 +01:00
Max Kellermann 53def9a682 increment version number to 0.20.13 2017-11-27 22:32:55 +01:00
Max Kellermann 2b3c1d640e release v0.20.12
-----BEGIN PGP SIGNATURE-----
 
 iQJEBAABCAAuFiEEA5IzWngIOJSkMBxDI26KWMbbRRIFAloZt0YQHG1heEBtdXNp
 Y3BkLm9yZwAKCRAjbopYxttFElF7D/9DIkK8ArcrqtGvLQFseOucf0FPmAD7csoq
 oDN4TL8UGUSYxcSt3wQqt6rp5JyWAFTuXPpneytqkZ0tW04y4kkvmIrRkYzuBLgt
 yupg1G5fRmidwcqdnb6LqgSdW66pY3U6keaED7LVnMrJbd5MM8R7FejiZFoWmD4C
 c9pUU79MbeRk0w2F9Ws0bkd+yU7lUiolcqOg2VK25MZnObI7qf+/fIKOVK0Q9Q2W
 AdHLHNliySYPBT/po5YN+VAWPcxSFHXkfN552x0N/U1D/klPLmP1q724frFT+DRQ
 vXC5ojDDmSc+uUGr8D5IESfzMOPFj5ag0SqPSNe7Cp5amcy/chNqmo/XKEGqtB+X
 BI/DfRHEPGz5wtz6x+AcxFdE6LBAjMpQ2H3ybxGDK1396dNsngAA/g8eyvnzie/2
 USQO10O9Ymhezt7lMqhMLxJC/5Q0JLsKRIgqCxABQfTh14JF+c5bkT3zetabA87r
 CSyHGr3+tN4KtSJwefGjaGTCy5lN1SB8bRgWVLVVpPYAvtsNS1LwwTyeI3AtYmxr
 fylkATAHawSXzdgxgzFA8GmscxaxO/gLud+9ekb33ZIq9bnXiOXpY5u98bxCPWkn
 JgzeC4E6xnI3Ft+Ss7Bu0zOgSl2jUiOV7zAy7z8Lo9Qv6QYuIvSi9m+Snxstkul0
 9QwG6bA+YA==
 =BUsZ
 -----END PGP SIGNATURE-----

Merge tag 'v0.20.12'

release v0.20.12
2017-11-25 19:47:56 +01:00
Max Kellermann 323231d1dd release v0.20.12 2017-11-25 19:32:37 +01:00
Max Kellermann 714011c81e lib/upnp: adapt to libupnp 1.8 API changes
Closes #155
2017-11-16 11:39:11 +01:00
Max Kellermann e2c81aa9ea Merge branch 'v0.20.x' 2017-11-14 12:31:13 +01:00
Max Kellermann 014f8cd693 output/httpd: flush encoder after tag
Without the flush, ReadPage() may not return any data, or not all
data.  This may result in incomplete ddata the new "header" page,
corrupting streams with some encoders such as Vorbis.

Fixes #145
2017-11-14 12:00:14 +01:00
Max Kellermann aea37e46e3 encoder/vorbis: default to quality 3
Don't require a quality or bitrate setting.  If nothing is set, don't
fail startup - just go with a good default.  A quality setting of 3 is
what "oggenc" defaults to as well.
2017-11-14 11:30:28 +01:00
Max Kellermann 31ab78ae8e input/{cdio,ffmpeg,file,smbclient}: unlock the mutex during blocking I/O
InputStream::Read() and InputStream::Seek() are called with the mutex
locked.  That means the implementation must not block, or unlock the
mutex before calling into blocking code.

Previously, a slow CD drive could stall the whole MPD process,
including the main thread, due to this problem.

Closes #149
2017-11-13 17:13:10 +01:00
Max Kellermann e4a147218b Merge branch 'v0.20.x' 2017-11-12 18:55:12 +01:00
Max Kellermann a2b77c8813 decoder/ffmpeg, test/test_protocol: catch exceptions by reference
Work around -Werror=catch-value.
2017-11-12 18:54:29 +01:00
Max Kellermann fef9747fbf output/shout: use MIME type instead of the encoder plugin name
This is more robust, for example it allows using the Shine encoder
plugin instead of LAME.
2017-11-10 21:52:54 +01:00
Max Kellermann 523051132d Merge branch 'v0.20.x' 2017-11-05 17:48:41 +01:00
cathugger b111a8fe8d output/Thread: ensure pending tags are flushed in all cases
Fixes hanging playback with soxr resampler.

Closes #139, #141
2017-11-05 17:42:32 +01:00
Marcin Jurkowski 3b23cf0258 decoder/vorbis: scale and clip tremor-decoded samples to 15 bits
Tremor decoder is unusable since commit 2ee43c4. Sound is distorted to
the point where it's nothing but noise.

The data from vorbis_synthesis_pcmout() needs to be scaled and
clipped for 16 bit sample size. For reference see
http://lists.xiph.org/pipermail/tremor/2010-April/001642.html and
http://lists.xiph.org/pipermail/vorbis/2006-October/026513.html.

Signed-off-by: Marcin Jurkowski <marcin1j@gmail.com>
2017-11-03 19:45:41 +01:00
Max Kellermann 28e864e096 player/Thread: log message when decoder is too slow 2017-10-25 20:26:09 +02:00
Max Kellermann 1de19b921a input/curl: call StartRequest() after setting CURLOPT_RANGE
It's not possible to set CURL options after curl_easy_perform(), and
thus the CURLOPT_RANGE had no effect.
2017-10-24 21:43:39 +02:00
Max Kellermann ab05b70423 ClientProcess: close connection when client sends HTTP request 2017-10-24 20:32:53 +02:00
Max Kellermann 338e1f5926 increment version number to 0.20.12 2017-10-24 17:31:55 +02:00
Max Kellermann b4b468eb27 release v0.20.11
-----BEGIN PGP SIGNATURE-----
 
 iQJEBAABCAAuFiEEA5IzWngIOJSkMBxDI26KWMbbRRIFAlnnDXYQHG1heEBtdXNp
 Y3BkLm9yZwAKCRAjbopYxttFEtPBD/4sOwd7sQr/eeJr5gqVpil+CaVkHN1GpVmF
 H72uYnp5eKREywLMAqrY86hxvykeflroHyNyBF7CV5hIZV8kPl1ApN6WvjG3oFeX
 ZnM6PQjeqgqczSVUZOd92nATJw6g/Vk0qbC+h6VwhpSoq5716dAKriSO25JzDg0L
 KOwEztVsLeziKrk/sHSKjgRrYpuNS8bFVxAY8Pk9MnUhEeHB3Rb7Spd2zMUfMDLF
 1pncFliIX5bOUKzDavIo4flAWc3jj514VhS7rVaU2OYpAdsQV18Z5Ze5B+46FUan
 2gsn3oCOVbC3QV7X0do5MtD9p1tyX0HREokY3ttgut+iRz9zym2m0uC6t1DXwyVI
 cugOF70JbBYxd/ChO4rFYPHZo6A1XE7hb89AcVf6EgZyXROK077EzptprW9et0Ge
 kIUbHs01lHfA7gFefEC+8iVGSXQmEmQQp5tBnZkdUaJdpxVULdMkhhHCNU8RIIVP
 ot8guH2/9oKkCj+ytHj37SUpk7bKjbzID9XIW5a+4rQPb1oRmQMvIeKgWZ6sjHP1
 5cS7l51q0onPmulfdQti0jTuaRcwQZcyKOxBU+eKYNHGNgLsdk1QDxyDhqbCCqWv
 0seA7h+lNBGqZL7/F6s0IxsTWIwaInkZWPE1EGSRe0wvZohDtBbNhXWQDPBlgl8O
 R42Jdx6PIg==
 =8U+o
 -----END PGP SIGNATURE-----

Merge tag 'v0.20.11'

release v0.20.11
2017-10-18 10:21:39 +02:00
Max Kellermann a7fdfa08e1 release v0.20.11 2017-10-18 10:14:46 +02:00
Max Kellermann 9703a401c5 Playlist{File,Save}: always use UTF-8 in playlists on Windows
Turns out that using CP_ACP is a lousy idea, because only very few
Unicode characters can be represented by it.  Instead, switch to UTF-8
(which every sane person on other operating system already uses).

Closes #102
2017-10-18 10:05:26 +02:00
Max Kellermann 91254e9211 queue/PlaylistControl: keep order list consistency in MoveOrderToCurrent()
Our previous use of Queue::SwapOrders() could cause surprising
results:

- sometimes, the old "current" song would be played again (if the
  newly selected song had not been played already)

- sometimes, the old "current" song would not be played again (if the
  newly selected song had already been played)

This is inconsistent, because it should not depend on whether the
newly selected song had already been played.

So instead of Queue::SwapOrders() we now use Queue::MoveOrderAfter()
and Queue::MoveOrderBefore(), which is more expensive, but also more
consistent.  It attempts to retain as much from the previous order
list as possible, and only moves the newly selected song around.
2017-10-18 09:05:47 +02:00
Max Kellermann fa67c2548a decoder/Thread: clear the command after catching an exception
If an early exception gets caught (e.g. from
AllocatedPath::FromUTF8Throw()) before
DecoderControl::CommandFinishedLocked() is called, the decoder thread
would go in an endless loop, because DecoderCommand::START is still
set.

Closes #118
2017-09-27 17:08:16 +02:00
John Regan ea80587ddb GME Plugin: fix track numbering
GME starts all track indexes at zero, but subtune prefixes
start at one. This fixes an off-by-one error during track
enumeration.
2017-09-27 11:18:03 +02:00
Max Kellermann af033c0d1d NEWS: mention the GME decoder change 2017-09-22 20:00:12 +02:00
Max Kellermann f6691579de Merge branch 'v0.20.x' 2017-09-20 23:57:28 +02:00
Max Kellermann 1295a1272a lib/icu/Compare: add fallback using strcasecmp() and strcasestr()
Our IcuCaseFold() fallback using strxfrm() is not actually case
insensitive.  This commit fixes the problem by switching to
strcasecmp().  That function is not guaranteed to support UTF-8, but
it's the best we can do in this sparse situation.

Closes #111
2017-09-20 23:43:27 +02:00
Max Kellermann 5ce93d6fa8 output/sndio: refuse to build with libroarsndio
RoarAudio's sndio emulation has been a source for annoyances.  First,
their headers turned out to be broken with C++, due to their use of
the "new" keyword.  Then they used a preprocessor macro to rename
"sio_hdl" to something else, effectively disallowing the use of
forward declarations.  Enough is enough, and I'm removing support for
it.

RoarAudio users should better use the RoarAudio output plugin.
2017-09-19 19:38:43 +02:00
Max Kellermann 20a5ef2798 NEWS: mention the sndio mixer plugin 2017-09-19 19:38:43 +02:00
Max Kellermann 44bbf42a9f Merge branch 'v0.20.x' 2017-09-19 18:58:02 +02:00
Charlie Waters b253a6b71e ffmpeg plugin: when decoded stream duration is unavailable, attempt fallback to container duration (fix MusicPlayerDaemon/MPD#110) 2017-09-18 10:39:27 +02:00
Max Kellermann 3f754fd350 Merge branch 'v0.20.x' 2017-09-04 08:27:08 +02:00
Max Kellermann f4f461b8bb storage/curl: support Content-Type application/xml 2017-09-01 11:32:40 +02:00
Max Kellermann f6abbc01bd increment version number to 0.20.11 2017-08-31 19:48:59 +02:00
Max Kellermann 0b93f52ba4 release v0.20.10
-----BEGIN PGP SIGNATURE-----
 
 iQJEBAABCAAuFiEEA5IzWngIOJSkMBxDI26KWMbbRRIFAlmefSAQHG1heEBtdXNp
 Y3BkLm9yZwAKCRAjbopYxttFEut8D/4oZgzdHTMbR6uYbFvkUmPrwtohq8N4JbaS
 /TtESfKPJ5PIv42MA5k89DjssQUz0uzuladsy+WXxTx8BD4naXaiOy7loDXjPcnu
 YL0sUdAKZVVBdau4dcumSQF0ewhUjuKZUt2I6W2Q35IpagV89nf+mHUXDtUrjykC
 coXIwrcINpi0MSo1pbS5m11XNOk2yPfl8ZR+9yn6AvaseCtrwxmogAJGK5bUSKUM
 NMaLffVLNfIL/YEBzm2RdgSyU4LBREKnO6vF7UCBSKHIVPyne83fbqc90COj7I9Q
 01LGowUAvJIoRIlMzjxlXO6S13hmXJlDZSECaaQYQjiC70RbC1+sK9tQtKQ4BqET
 C+vG9ysfqVi4bsYkOppR5JDE9NcghkjK+iGwBYVdXmRwGzmdb1W6fWgAqYGRF+Ql
 Fg+/htruNsvvuO+RtcOd8WJWpP3nKisGu9jRp7dceAsWGE20M8HTjCeSZsZM+LvU
 B9Lp9NplKqkJyq2k81OUmGBWkR7t8okMeZGvon+sExZ285giryOfhao4eEX7CBqy
 XHlClydNnBW11R6TEzhjIxCDufPdboM0XHVxX4kutfkPVGkPnJR/8Jk0c+d7AiVE
 H5MSgWsOu9fN//nIuUxdODtL5VMw45/hdydZ9YMI/RnwMQFdEqAZmBvMKE7ZLqrI
 F80eZ8/nQg==
 =b8hp
 -----END PGP SIGNATURE-----

Merge tag 'v0.20.10'

release v0.20.10
2017-08-24 09:35:34 +02:00
Max Kellermann 57a71c157d release v0.20.10 2017-08-24 09:15:43 +02:00
Max Kellermann a00d412008 player/Thread: initialize play_audio_format, fixes assertion
This fixes an assertion failure caused by resuming playback before the
decoder has finished startup.
2017-08-23 17:43:49 +02:00
Matthew Leon aa9c6062b0 Merge branch 'v0.20.x' into master
contains OSX mixer
2017-08-22 10:36:37 +01:00
Matthew Leon 5fb39658f1 OSX mixer 2017-08-21 20:05:50 +01:00
Max Kellermann fe9ffcb9d2 Merge branch 'v0.20.x' 2017-08-08 19:30:30 +02:00
Max Kellermann b0703b92c3 util/FormatString: pass the allocated buffer to AllocatedString::Donate()
.. and not the stack buffer.  This made the AllocatedString destructor
crash.

Closes #52
2017-08-03 00:25:30 +02:00
Max Kellermann d29bdf3e81 Merge branch 'v0.20.x' 2017-07-31 13:50:14 +02:00
Max Kellermann dd9fd3d8a7 tag/Aiff: the FORM chunk size is big-endian
Was broken by commit 8a86460b8f

Closes #87
2017-07-31 13:46:09 +02:00
Matthew Leon 4c0404c70d Check for MusicBrainz id3v2 tags in ffmpeg.
Addresses #82.

Previously, the ffmpeg decoder only checked for the "generic"
MusicBrainz metadata keys used in other metadata container formats.
2017-07-20 08:28:14 +02:00
Max Kellermann 5ed5d7fe60 Merge branch 'v0.20.x' 2017-06-15 22:51:07 +02:00
Max Kellermann 58a99f1907 increment version number to 0.20.10 2017-06-15 21:35:23 +02:00
Max Kellermann 979f1b6c39 release v0.20.9
-----BEGIN PGP SIGNATURE-----
 
 iQJEBAABCAAuFiEEA5IzWngIOJSkMBxDI26KWMbbRRIFAlkz5jkQHG1heEBtdXNp
 Y3BkLm9yZwAKCRAjbopYxttFEubuD/kBXMcV4XawqGNNtSHdrY8CxSL8wJMCMJQl
 aMgRkKLPRml8Hj9FNNG9pjXBuT+qUgPX7t9gBEiT7c+sV3fHH40gUf1js5GIsEPm
 BAVfvww5EhmQWWVhPTLk1iZ4jp6E96mDmIG1znwo7etSZHXU8RJfR7woBi3SPJ9f
 OPcrimskNuWpAWeaEIKi/1Iwzy8d9VK9Ttb73gA3M5zSm7ioXzt3YClpwLRM8JU6
 QeUJchy6VwXnygswjUNmbhPc3GsD2FyUZ4OtJ0hodnqqajfldBxhcHUnQk4zZULr
 1nLSyOuA9bwLuFohH1T6HiY9z8PFzgqdIHvsjOJgZ4gQa69PVNjal2tUEUav9zFv
 aK4LvTVPnIk+hqRbtLpV7/rPKuClrC9BO4oYdBGBDNY4hqVpvRA9obP1s00aOi+K
 UhYqLqg7yeIEeTlUxFOhXJCKAEL69BuXT5ihJtDlB/dCUzv37sEch/4WDgs7uc+O
 9kJYlElvozw57mbczsee/PCSnSWrLCq/qG/bNEUUQOTueWNuifh3PL62UXGgfbEH
 01hJDyLr6ETSmWn7rjTfLJiHThX/EQQvOhs+35fbCyry65z4tFwrilGDmFVUWGPq
 /6QEpY1D6q4fkoma/iWOZoTkfKewatAPGMGWoJaGhCnfQFz4VTFtS2bDtuUctQ16
 jnXnPFxqBw==
 =0SSp
 -----END PGP SIGNATURE-----

Merge tag 'v0.20.9'

release v0.20.9
2017-06-04 12:57:05 +02:00
Max Kellermann cf86dfd317 release v0.20.9 2017-06-04 12:51:36 +02:00
Max Kellermann 62b03cfddf storage, db, mixer, command: remove more bogus "pure" attributes
This commit is similar to 788e3b31e1,
and removes more "pure" attributes which were placed on functions that
could throw exceptions, which is illegal according to clang's
understanding of the attribute (but not according to GCC's).  GitHub
issue #58 was most likely about StorageDirectoryReader::GetInfo() and
Storage::GetInfo(), which still had "pure" attributes.

Closes #58
2017-06-03 21:54:24 +02:00
Jörg Raftopoulos 18b827b979 decoder/ffmpeg: add support for adx
Add ffmpeg decoder support for *.adx files (Sega game console)

Closes #60
2017-06-03 20:57:20 +02:00
Max Kellermann 0a379fc514 system/ByteOrder: fix byte order detection on FreeBSD/aarch64
Patch from
 https://svnweb.freebsd.org/ports/head/audio/musicpd/files/patch-src_system_ByteOrder.hxx?revision=441921&view=co
(with a tiny modification)

Closes #59
2017-05-29 20:37:14 +02:00
Max Kellermann 445c11b8d9 increment version number to 0.20.9 2017-05-29 20:36:08 +02:00
Max Kellermann 86d05e98e5 release v0.20.8
-----BEGIN PGP SIGNATURE-----
 
 iQJEBAABCAAuFiEEA5IzWngIOJSkMBxDI26KWMbbRRIFAlkfNQ4QHG1heEBtdXNp
 Y3BkLm9yZwAKCRAjbopYxttFEm0/D/92uGQTZ8x3qMpMN7R0jw4GBYjkqCDtz2wH
 UujnfqUZfr852wkFBP3LiraicGr5dzsRwM272hlXeMDp3s3EPT8eNIgwiETDreD/
 NpA/Pqyl4ZfvyPGkrtvW2ZMWENVrGjAoygHQr3evemIdH5ypxWCzSaNbiOyeabqp
 +HqyOFeJckUHC70A2vOU8jredhGFYWOdKRZT9WRdBLTwaKd80DRmsKxi8d5Yc/ms
 nVeGCVpF9OpyjlJu0+7v3DT0ekgTJI2CihZT3GdasCRllPa397uHiqKeah2DkOId
 z1AMcxhzR+tz4cafW5iz8xtyIDdXPL+SD58wkuUDJO2ePCNRLTt1zW9ijJFWzocu
 o6MTyn7mpN2Zp/dLLUrxNkNKTT/YvaaGBIn4fuLPbGQXNjITyVRkw233fOz/6c39
 EOcR86ws60e4F2JLbxN3lEKL5bLkLPNK2J+xWEpRHGXy5Bfn6C8uQklno3h3urHG
 DI2p+3og/+7I+MNOX88CMZBdNpfqiWKNSrSAAsi99CwIXIYz0qlKPx9qQyTK0wyh
 xPrU/j5GGQqR2eoR6eChiB3LOE8SLxfeLgrMJ2HB+w550F4KxaCVxpxpWI3D0GX8
 +tC4uDE+LkGdOc1pbOYUHQWNhFwy3jRxo+wkcb5wz5QXBVVEGlYqo5BcSeX1Clx+
 kiO3g9SNlg==
 =mUPF
 -----END PGP SIGNATURE-----

Merge tag 'v0.20.8'

release v0.20.8
2017-05-19 20:13:01 +02:00
Max Kellermann 8d290ad509 release v0.20.8 2017-05-19 20:10:22 +02:00
Mario Di Raimondo ffa676f577 playlist/m3u: support for mime-type `audio-mpegurl` for M3U playlists 2017-05-19 15:25:58 +02:00
Max Kellermann 0a3a5a7c65 Merge branch 'v0.20.x' 2017-05-16 10:09:20 +02:00
Max Kellermann 64786ec12a Main: omit "constexpr" on MIN_BUFFER_SIZE with GCC 4.x 2017-05-16 07:20:47 +02:00
Max Kellermann b3c82f8886 output/{osx,haiku,pulse,sles}: add missing "noexcept"
Fixes build failure on OS X, closes #44.  With the other plugins,
that's not critical, because those use the AudioOutputWrapper, which
hides this problem.
2017-05-16 07:12:30 +02:00
Max Kellermann 063259dc52 increment version number to 0.20.8 2017-05-16 07:06:57 +02:00
Max Kellermann 4faef28cc5 release v0.20.7
-----BEGIN PGP SIGNATURE-----
 
 iQJEBAABCAAuFiEEA5IzWngIOJSkMBxDI26KWMbbRRIFAlkaFL0QHG1heEBtdXNp
 Y3BkLm9yZwAKCRAjbopYxttFEr4ID/9iAQC+7fFv06uLOm48Ufu+PgoD8uJkAwF5
 QuLQkc85g9urn+bu9N7Qs7Vypp7aLyGcJKY0jyA8wxkOj24pUC3GYk80daUt561V
 5s20FnoS/Uoman3CSJL94IfCUBxejizE6vgIIHTc5bb6U0qIsPub/8JTTE2Ih7uP
 nvFZ5uBQ+YTc7at+iIH9123eUMKkitkh8osNblovqQT9v42++Tm4ztAytRHBjwUA
 Itew5HhlvahbLKqFs/7vmICh/YX1FcOV7cV+erEWYfkH0KCI2bhSle4u2d0CBOvD
 VJlDnBCo9bM7WKcPYqJiFFFXA0CRk06wbkkkAtwF4zjp8xos7aQcq4FyQnYL8KXo
 5lijIhRwBURBd+nt8oA9kuEhBt/T75otcemJkzVaYappHTJCLjhxSGcPt8mw+nE9
 9WQzsp/MIVzg9l5g3D9S/43xM7uhvn98Tn1Qf2s8YRd2o8CZeOhW+X3RvbCvVPv2
 mOlx4sFAv8DOJ3KxMdqiJT+PmylPyJluQdqH+tMc8BdPg/kpSpYIPTuSjjRqK1yh
 ld5do0HtAAwiHtvXfk5YVFjJSpO0c8yVn6xci2Cl4k/5ZHj2UE1ln+N5vCea2BRF
 2J3HAjROwtcwY3lU1jFnEAogf24KWiFJqhhC0EqBGUdlrM8Dn37P5cEWWjROIMNK
 lPEdovokNw==
 =CdDy
 -----END PGP SIGNATURE-----

Merge tag 'v0.20.7'

release v0.20.7
2017-05-15 23:01:49 +02:00
Max Kellermann b4c9d9c2a7 release v0.20.7 2017-05-15 22:51:08 +02:00
Max Kellermann fa2b59df4b Main: cap buffer_before_play at 80% to prevent deadlock
Closes #34
2017-05-15 22:49:31 +02:00
Max Kellermann f41a169460 Main: enforce a reasonable minimum audio_buffer_size setting 2017-05-15 22:44:18 +02:00
Max Kellermann 788e3b31e1 *: remove "pure" and "const" attributes from throwing functions
The "pure" and "const" attributes are not so well-defined, and a
recent clang version implements an optimization which pushes the
definition's boundary beyond what I believed it was.  clang now
assumes that functions declared "pure" cannot throw exceptions, even
if they lack the "noexcept" specification.

When compiled with this new clang version, MPD will crash randomly if
an exception happens to get thrown by such as "pure" function
(https://github.com/MusicPlayerDaemon/MPD/issues/41).

This commit removes all such misplaced "pure" and "const" attributes,
closing #41.
2017-05-08 17:25:06 +02:00
Max Kellermann b0ce551523 decoder/pcm: support audio/L24
Closes #31
2017-04-24 20:54:13 +02:00
Max Kellermann f6e428ac22 Merge branch 'v0.20.x' 2017-04-24 11:44:27 +02:00
Max Kellermann 95b62a843a Merge branch 'add-original-year-tag' of git://github.com/tremby/MPD 2017-04-21 18:55:34 +02:00
Max Kellermann 504f5f7bdd storage/FileInfo, db/simple/Directory: use 64 bit for device/inode
An ino_t is usually a 64 bit integer, and some file systems (such as
Linux's kernel NFS client) really uses the upper 32 bit.  This can
lead to false positives in the directory loop detection in
FindAncestorLoop().  Increasing these two attributes (in
StorageFileInfo and Directory) to 64 bit adds little overhead, but
makes the check a lot safer.
2017-04-06 09:58:25 +02:00
Max Kellermann 32bcad51b8 configure.ac: prepare for 0.20.7 2017-03-16 10:50:12 +01:00
Max Kellermann e26d49efb7 release v0.20.6
-----BEGIN PGP SIGNATURE-----
 
 iQJEBAABCAAuFiEEA5IzWngIOJSkMBxDI26KWMbbRRIFAljCzQcQHG1heEBtdXNp
 Y3BkLm9yZwAKCRAjbopYxttFEnIXD/9ltsmg3VC81NHOmcUehFgUaLyNh8o2iEr9
 tQfdydQxfTXBIGztMoPsPz71da8BIqAgMTCTGAEpTUXIW6ViGkgsoDlR2fAOagG2
 ybHn2q3WsPERJvkGZ4xIo0ti0pLLy7wrFpmShgOKuwb6YqOgSV+rbu/CaQanxVJE
 S599vo6rV/OI4KFSYWJbfafifN/Mqmzfl/D/tB5xaMvhas60XZ6pZTp/xH8OlnML
 8qkgPmN3gJe7DPq6L3rdwKobJuS1X6NLHSp1DyGVRy68B0sd3tMmbOocMeyi1OlE
 1z/n/M+dcSUhdHAh/Pg0wrvH0UpUlJ11blSDiWB9gqr9oOvCZO+OcPCnk0QJrqq+
 qselDNWBLvVPESbxlPO4OUbV6jxPPhVgz18RYl6JaJeUFjXkuiytI/t6jsbVM3+f
 ZC1UgO+TznCuDjjMj35RP9QDkUQpuH6CK4+tyxbH7Fe4KQi02FQdtK8Q/CnESBLl
 alTLYQk7VlwL1oMgezoZfTLDbsihRrEO6Y0cp/pObUrEjQ65706UGUf61PRQGBM9
 DlEPqfuH8TMgksxDIrkt68pWjyCXhhUCA+RsyFJoMp7Xq6Gy2pZUn2yKCmTXLte/
 v5xW9FuiSvKUKlvYbfk/q3u/GTCJELf0eY3y0Eryqp6nOEZHmzz8HOF7Bs2PxM3B
 eU/fEKWxVQ==
 =21bM
 -----END PGP SIGNATURE-----

Merge tag 'v0.20.6'

release v0.20.6
2017-03-10 17:02:32 +01:00
Max Kellermann a40510c241 release v0.20.6 2017-03-10 16:57:59 +01:00
Max Kellermann ac8dce6599 lib/curl/Request: "ICY 200 OK" is a response boundary header 2017-03-10 16:28:02 +01:00
Max Kellermann 1b6666fa39 Partition: handle SYNC_WITH_PLAYER before TAG_MODIFIED
The TAG_MODIFIED handler (i.e. playlist::TagModified()) works only if
the modified song is the current song - something that is not updated
until SYNC_WITH_PLAYER is finished.  This fixes tag updates right
after a new song is started.
2017-03-10 16:11:34 +01:00
Max Kellermann 1dd01c99e8 decoder/sidplay: make compatible with libsidplayfp < 1.8
https://bugs.musicpd.org/view.php?id=4665
2017-03-10 13:48:52 +01:00
Max Kellermann 3be2051808 decoder/Thread: check ENABLE_FFMPEG, not HAVE_FFMPEG
This repairs the damage to commit 74dbaade6f done by commit
b3f5b4932c
2017-03-01 17:06:23 +01:00
Max Kellermann e22a4fdba4 command/Error: improve libstdc++ 4.9.x detection for std::rethrow_if_nested() workaround 2017-03-01 16:38:22 +01:00
Max Kellermann 29a7b2c5b5 decoder/mpcdec: ignore empty frames
https://bugs.musicpd.org/view.php?id=4656 describes a crash due to
division by zero because frame.samples==0.  This should never happen,
but apparently can happen after seeking.  The best we can do is to
just ignore this frame.
2017-03-01 16:13:21 +01:00
Max Kellermann 3b6c285c2a configure.ac: prepare for 0.20.6 2017-03-01 16:13:21 +01:00
Max Kellermann 29d03ab937 release v0.20.5
-----BEGIN PGP SIGNATURE-----
 
 iQJEBAABCAAuFiEEA5IzWngIOJSkMBxDI26KWMbbRRIFAlirVtMQHG1heEBtdXNp
 Y3BkLm9yZwAKCRAjbopYxttFEgbaD/9tgcgcnbiWGkNDMf0qfqfaiY80wA4HbSBT
 qbKzan/kuiPXL6xcgw8YRYdAjyaIyw//f1q0SL8/LKvVQ4CrlTEQzOQUzrAOe02n
 m35/6YKZVzziMRwuSZY4oQ4WH7SE87gthYIykRt59adznr2QNtQe53SnXd8ukGtf
 l8xlLNuIiEwIo5PZ8ObEZH1dUP1PWtfJlxQfbJ2JhZTOR/qPfrpIzSK4GVY0ZXdz
 EO6BIZyDgPfeZCPBZqiKmw4vcdIHBhG9ZgtOhX3YATV7ZSYqmjrUcjzEsoyQlOaH
 rhe/whl272TQYdj95//BnqI899NVSNRYg6XXGlCB5TXqFscoDCW6JXvVAaTfB0Yg
 vMV7ZYX8auu2i013O51yoj8/ofNmOjqbX9eui+gJx6Xb6Zr9Ttma5woYRh14NXwd
 15KObGCd1LADpiOZ2XQ8Snlu8QlZ+PXr8RpLh9uSwDe7heemMRKqDZEf3AxfP3wO
 GUOK4EHfZ5kZQHlWLA3u59Zopo1ZJjL6EJUTG3Qk+n/Wob/S2F/v5IFIdyaEFTKI
 hrcTEQ/EmXZ9vc5Iw/LnIM49pO3kZXKQ9bSrZoi0kjk2AN6XBMmJNoYv/+huc2U9
 JiCcyM8olCWcSQnPGjoHWxBGLhxNXtR+WYu/tEEq3+D2PFdkfOap3ApP1qdi+JPd
 JFps/sOkgQ==
 =4+OJ
 -----END PGP SIGNATURE-----

Merge tag 'v0.20.5'

release v0.20.5
2017-02-20 21:59:40 +01:00
Max Kellermann 575d1786af release v0.20.5 2017-02-20 21:51:31 +01:00
Max Kellermann 7e46277016 Merge branch 'v0.20.x' 2017-02-19 19:46:18 +01:00
Max Kellermann 4bb83781e8 output/httpd/IcyMetaDataServer: cast length to unsigned
Fixes another buffer overflow: if the stream has a very long title or
URL, resulting in a metadata string of more than 2 kB, icy_string[0]
is a negative value, which gets casted to size_t - ouch!

 https://bugs.musicpd.org/view.php?id=4652
2017-02-19 19:28:52 +01:00
Max Kellermann b1c7649edb output/alsa: non-blocking mode
Use SND_PCM_NONBLOCK, and perform all snd_pcm_writei() calls in the
IOThread.  Use a lockless queue to copy data from the OutputThread to
the IOThread.

This rather major change aims to improve MPD's internal latency.  All
waits are now under MPD's control, instead of blocking inside
libasound2.

As a side effect, an output's filter is now decoupled from the actual
device I/O, which solves a major latency problem with the conversion
filter on slow CPUs and small period buffers.  See:

 https://bugs.musicpd.org/view.php?id=3900
2017-02-09 21:36:18 +01:00
Max Kellermann 67a958a326 Merge branch 'v0.20.x' 2017-02-09 21:24:20 +01:00
Max Kellermann 29e1b6e465 mixer/alsa: reset the MultiSocketMonitor in the destructor
Fixes potential crash bug.
2017-02-09 21:13:19 +01:00
Max Kellermann 3c55487a16 configure.ac: don't require libsidutils when building with libsidplayfp
The libsidplayfp fork has merged libsidutils into the main library.
The libsidutils we used to link with was part of the original
libsidplay project.
2017-02-09 13:09:03 +01:00
Max Kellermann 3850716522 command/Database: add "sort" parameter to "find" and "search"
Implement the second part of https://bugs.musicpd.org/view.php?id=3990
2017-02-08 11:22:08 +01:00
Max Kellermann 29453ba196 client: add tag_mask attribute
The "tagtypes" command now has several sub commands which can be used
to edit that mask.
2017-02-08 09:06:11 +01:00
Max Kellermann 07ce915c66 Merge branch 'v0.20.x' 2017-02-08 08:45:24 +01:00
Max Kellermann 81a97315e3 NEWS: mention ID3 memory leak fix 2017-02-08 08:44:47 +01:00
Max Kellermann 45cadef22f configure.ac: prepare for 0.20.5 2017-02-06 23:28:36 +01:00
Max Kellermann df4af2b550 release v0.20.4
-----BEGIN PGP SIGNATURE-----
 
 iQJEBAABCAAuFiEEA5IzWngIOJSkMBxDI26KWMbbRRIFAliSTDkQHG1heEBtdXNp
 Y3BkLm9yZwAKCRAjbopYxttFEsIQD/4iNkylzLp8mID2aFT690MFzv4TRXi2XS7v
 r3Rlx3hpGyDdzeXZeFc5zxsc9Ei8OfLcdFC/Umj9LjQanXakOxwsdhagrW9cadNX
 YLxkyVcREXalmzUvoWeRnya1LjoTdYA8llvG2tAJosXVr0o/GHZi56aHcrYnW2a6
 XD8kEk5k9beuEcBLk1rdZCTGPbVLwCFvMcpZ7j5Hd4kDGQjjw2aoEaPWchJdhLQh
 p+GRSU+A8hyTo9zy+aNO3cKvq6zqVxDLlHnIqh8XPWQoLPyWuD7ETvwERKmdmiPZ
 bSo0MR7azTlhkWbNZxjPHgZuacJDlwKvXPg1ofjn8VVcaVe5ONeX+1WP0ozUYqyU
 fmhLxMHKuwZcKo6do/jNhAVp//VBWhSwJHPA8kjBTuZHHc0HvgyTxlAgvzlrSswe
 dxc8vnvzgJfUKz5k7mf3amVg6Cu1CmNi59CkyL0NL+8N0inyMfdeQuQEYgbPoI6X
 jIRwACfXpMX75VtiDaNpnFLBjL5emE6u2bDoU2c5ezgpthaWjb0PqSmoLBBF8TNm
 k0ecXlIwCjT3pDcqmFdqgG3AJiYLTgX0rETC8PInl6toLzr2oVMVlijU3YK5PjMl
 nTvgs8TwprTWImgcBnidqRMb39p3AKs12pHfZ4Y5Iu82Bm60acZQMkv6sQh43Wyc
 +W2+T3D2IA==
 =b2Fz
 -----END PGP SIGNATURE-----

Merge tag 'v0.20.4'

release v0.20.4
2017-02-01 22:05:33 +01:00
Max Kellermann 0a033fb10a release v0.20.4 2017-02-01 21:59:36 +01:00
Max Kellermann 05eac20ffe lib/nfs/Connection: detect libnfs reconnect
When rpc_reconnect_requeue() gets called from inside nfs_service(),
the NfsInputStream can stall completely because the old socket has
been unregistered from epoll automatically, but the new one has never
been registered.  Therefore, nfs_service() will never be called again.

This kludge attempts to detect this condition by checking
nfs_which_events()==POLLOUT.

https://bugs.musicpd.org/view.php?id=4081
2017-02-01 21:36:58 +01:00
Max Kellermann 38d263ac19 output/sndio: work around a libroar C++ incompatibility
Same as in commit e02d8ad8d2, but this time for the sndio plugin
which can be emulated by libroar.
2017-02-01 19:53:23 +01:00
Thomas Zander 51147203be free() require cstdlib to be included 2017-01-31 21:21:37 +01:00
Max Kellermann a931686317 pcm/SampleFormat: workaround for GCC 4.9 "constexpr" bug
GCC 4.9 has incomplete C++14 support.  Specifically, it doesn't allow
switch/case in "constexpr" functions.
2017-01-27 11:02:58 +01:00
Max Kellermann bb097109f0 configure.ac: prepare for 0.20.4 2017-01-27 08:47:36 +01:00
Max Kellermann 872ecc1aed configure.ac: prepare for 0.21 2017-01-25 08:58:07 +01:00
Max Kellermann 2ab6c40ff1 release v0.20.3 2017-01-25 08:53:16 +01:00
Max Kellermann 32a64481f2 lib/upnp: fix bad std::chrono cast
libupnp provides seconds, not whatever time unit is used by
std::chrono::steady_clock.
2017-01-23 19:16:14 +01:00
Max Kellermann e78ab767d3 db/proxy: make connect errors during startup non-fatal 2017-01-23 18:55:40 +01:00
Max Kellermann c6f89c42b2 db/proxy: make the base class of LibmpdclientError public
If the base class is not accessible, the "catching" the base class
won't work.  This caused the fatal error:

 terminate called after throwing an instance of 'LibmpdclientError'
2017-01-23 18:28:40 +01:00
Max Kellermann 5e93cfdd9e output/Source: reset the ReplayGain serials ion OpenFilter()
Each close/open cycle resets the Filter's state, because a new Filter
instance is being created.  That results in the serials
(replay_gain_serial and other_replay_gain_serial) being out of sync
with the internal ReplayGainFilter state.

So instead of initializing those serials once, we need to initialize
them each time we create new ReplayGainFilter instances, i.e. in
OpenFilter().

 https://bugs.musicpd.org/view.php?id=4632
2017-01-23 17:55:04 +01:00
Max Kellermann 33716732a1 pcm/PcmChannels: silence surround channels when converting from stereo
Previously, there was no special code to convert stereo to
multi-channel.  The generic solution for this was to convert to mono,
and then copy the result to all channels.  That's a pretty bad
solution, but at least something which always renders audio.  MPD does
something, instead of failing.

Now that MPD has proper support for multi-channel (by defining the
channel order), we can do better than that.  It is a (somewhat) common
case to play back stereo music on a DAC which can only do
multi-channel.  The best approach here is to copy the stereo channels
to front-left and front-right, and apply the "silence" pattern to all
other channels.
2017-01-19 10:53:41 +01:00
Max Kellermann d7137586a9 Audio{Format,Parser}: use shortcuts such as "dsd64" in log messages 2017-01-17 22:42:23 +01:00
Max Kellermann dcbab8e37a PlaylistFile: "playlistadd" creates new playlist if it does not exist, as documented 2017-01-16 20:55:19 +01:00