Max Kellermann
f29949e14d
command/Error: support class Error as C++ exception
2016-09-08 10:34:02 +02:00
Max Kellermann
75aa98ddaa
command/Error: merge the two try/catch blocks
2016-09-08 10:34:02 +02:00
Max Kellermann
06909f4f00
util/Error: remove explicit move constructor, allow copying
...
The C++ compiler will auto-generate move and copy
constructors/operators for us.
2016-09-08 10:34:02 +02:00
Max Kellermann
aca081557a
queue/PlaylistControl: use PlaylistError::NotPlaying()
2016-09-05 20:37:24 +02:00
Max Kellermann
a71efacd1e
queue/PlaylistControl: fix return value in PlayNext(), PlayPrevious()
...
Failure must be indicated by returning false.
2016-09-05 19:21:23 +02:00
Max Kellermann
871063dab7
neighbor/Plugin: migrate from class Error to C++ exceptions
2016-09-05 11:37:58 +02:00
Max Kellermann
135662d6b0
lib/smbclient/Init: throw std::runtime_error on error
2016-09-05 11:32:20 +02:00
Max Kellermann
a69c3c1848
neighbor/Glue: support C++ exceptions
2016-09-05 11:31:23 +02:00
Max Kellermann
50e5244e25
input/Init: support C++ exceptions
2016-09-05 11:28:05 +02:00
Max Kellermann
1c07f197de
Filter/Plugin: migrate from class Error to C++ exceptions
2016-09-04 20:07:05 +02:00
Max Kellermann
13c32111a0
Filter/Internal: migrate from class Error to C++ exceptions
2016-09-04 19:38:41 +02:00
Max Kellermann
28c6975732
filter/AutoConvert: use std::unique_ptr
2016-09-04 19:36:50 +02:00
Max Kellermann
12091fcfb1
thread/Util: throw exception on error
2016-09-04 15:15:11 +02:00
Max Kellermann
5598826eaf
thread/Util: un-inline the functions
...
Reduce header clutter.
2016-09-04 15:11:56 +02:00
Max Kellermann
3fea624cca
output/Thread: use Close() after error in ReopenFilter()
...
Now that CloseFilter() may be called again, we can reduce code
duplication.
2016-09-04 15:09:51 +02:00
Max Kellermann
9007dd9ab7
output/Thread: clear Filter pointers in CloseFilter()
...
This allows calling CloseFilter() multiple times.
2016-09-04 15:09:05 +02:00
Max Kellermann
08166cf330
output/Internal: initialize the Filter pointers
...
With the configuration "replay_gain_handler none", the Filter pointers
are never initialized, which can crash MPD.
https://bugs.musicpd.org/view.php?id=4571
2016-09-04 15:05:42 +02:00
Max Kellermann
e51b6a6233
Filter/Internal: remove outdated API documentation
2016-09-04 14:42:27 +02:00
Max Kellermann
3887465d80
Log: add FormatError() overload with std::exception
2016-09-04 14:34:47 +02:00
Max Kellermann
d84f96a571
fs/io/FileOutputStream: add mode CREATE_VISIBLE
2016-09-04 13:16:37 +02:00
Max Kellermann
f600e226da
fs/io/FileOutputStream: add mode APPEND_OR_CREATE
2016-09-04 13:16:33 +02:00
Max Kellermann
d775f13a03
fs/io/FileOutputStream: merge all classes into one, add enum Mode
...
Prepare to add more modes.
2016-09-04 12:57:41 +02:00
Max Kellermann
b630afdeda
fs/io/BufferedOutputStream: add wchar_t overloads
2016-09-04 12:57:41 +02:00
Max Kellermann
c39c259078
fs/io/BufferedOutputStream: add Write(char)
2016-09-04 12:57:41 +02:00
Max Kellermann
a571c4ba33
tag/Item: remove "packed" attribute, add static_assert on alignment instead
...
The "packed" attribute triggers a clang 4.0 warning, and it's not
necessary. All we want is correct allocation of this
dynamically-sized struct.
2016-09-04 12:57:41 +02:00
Max Kellermann
889be6e29d
fs/io/FileReader: add methods GetSize(), GetPosition()
2016-08-27 12:20:59 +02:00
Max Kellermann
d15f64ae5d
fs/io/BufferedReader: add method Reset()
2016-08-27 12:09:57 +02:00
Max Kellermann
a07117ea55
fs/io/FileReader: add method Rewind()
2016-08-27 12:09:17 +02:00
Max Kellermann
d0dae177cf
release v0.19.19
...
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
iQIcBAABCAAGBQJXvAb+AAoJECNuiljG20USLukP/1dWwG4U3eQllGtwmKYEuGT8
x8bFImW3zziQgzzQNos8ZyB/7Q9wFDwl90q2Shyg778sk8WgBLVdn1hLhDRyodkg
iTAbnuBeX0GoQO2vZ62jY/xtsSMwCguNMbJe5Yybq+uZ2EYLQO8NWsvy/qZzZRB6
9s78IfQodN/vbKg8cJDPP1ZFvlhC+RfrOJbhwkAhh3D0xkpYjumW636ewcpD5Crk
T+OT035konZEcH2hOy89tleFifo+/nosiJQXL5/RdfIVAy+rWj9HbKMT9Wlb2EO0
iqvbjfC8rAt4a15Y8l/C42m1xhLFtRvI7O5I5wH8zqwpgRfCuG21Kw49zWFQ9md/
tX2urKZC6QsvxfHx4J6ot+SFQJB/VZ1fufG1ZBTHVNp7eJ++mWE5pR79EbCLurlj
x7cN1ZM7wsQfkw8MOsKr+sJqIGkU9sZSHHh3PhEkI83fEssYaAOGtkPuTqU0w/37
wHV2laFD58SOagVPbQlhIdK6MnkiTR8RvV9j6ERywLnFNMBMiI9j7ij7zoDMKjSU
E60JzIR4xUPWtQg91BwM5sJdqZw7xybgNBn0rMt+6AoA0CQseAnPRxA9gstrWR1/
FYRPUzrf9brpvXEsT8R2tXcjNLNYgKzT3GxHEQj1k2MJiVe+1SztiYIi77JPLJfn
MevaiCy/Ho3ZeQKygxVq
=GsV+
-----END PGP SIGNATURE-----
Merge tag 'v0.19.19'
release v0.19.19
2016-08-23 10:27:39 +02:00
Thomas Klausner
de0752fd56
system/ByteOrder: gssupport non-x86 NetBSD
2016-08-23 10:15:54 +02:00
Max Kellermann
4204d4928b
decoder/ffmpeg: no avcodec_parameters_to_context() with FFmpeg 3.0
...
This function exists since FFmpeg 3.1. Fix a build failure with
FFmpeg 3.0.
2016-08-23 10:15:54 +02:00
Earnestly
e2f6cc9c9f
Don't overwrite ss.format
...
Currently the switch statement is invalidated by ss.format being overwritten
with the default value of PA_SIMPLE_S16NE which results in white noise during
playback as my server is expected S16LE (S16NE).
Signed-off-by: Earnestly <zibeon@gmail.com>
2016-08-23 10:01:56 +02:00
Max Kellermann
05de0ecec3
decoder/ffmpeg: call avcodec_parameters_to_context()
...
These bug reports describe problems with some FFmpeg codecs:
https://bugs.musicpd.org/view.php?id=4564
https://bugs.musicpd.org/view.php?id=4568
https://bugs.musicpd.org/view.php?id=4572
According to the FFmpeg bug tracker, a call to
avcodec_parameters_to_context() is required after
avcodec_alloc_context3():
https://trac.ffmpeg.org/ticket/5781
This requirement was previously undocumented.
2016-08-23 09:59:25 +02:00
Max Kellermann
b05beb000f
Compiler.h: work around clang 3.9 warning -Wexpansion-to-defined
...
Check {GCC,CLANG}_VERSION==0 or >0 instead of using defined(), which
may render undefined behavior.
2016-08-23 09:59:25 +02:00
Max Kellermann
093abaad29
Compiler.h: always define CLANG_VERSION
2016-08-23 09:54:09 +02:00
Max Kellermann
e84e4169f9
Compiler.h: remove redundant __GNUC__ check
...
GCC_VERSION>0 implies defined(__GNUC__).
2016-08-23 09:53:17 +02:00
Max Kellermann
cd6c5cfd4c
Compiler.h: exclude clang from GCC_CHECK_VERSION()
2016-08-23 09:52:14 +02:00
Max Kellermann
b855f2fcc2
Chrono: use macro GCC_OLDER_THAN()
2016-08-23 09:51:41 +02:00
Max Kellermann
ba69ade024
Compiler.h: add macro CLANG_OR_GCC_VERSION()
2016-08-23 09:48:58 +02:00
Max Kellermann
8748b2dc3f
fs/io/BufferedReader: add ReadFull(size_t)
2016-08-16 12:09:04 +02:00
Max Kellermann
5f66af3712
fs/io/BufferedReader: add missing Consume() call
2016-08-16 11:47:31 +02:00
Max Kellermann
31ae50b137
fs/io/BufferedReader: add method ReadFull()
2016-08-16 08:46:44 +02:00
Max Kellermann
87e0459fcc
util/WritableBuffer: add method skip_front()
2016-08-16 08:46:30 +02:00
Max Kellermann
07e58ae64f
fs/io/FileReader: add missing include
2016-08-16 07:58:44 +02:00
Max Kellermann
a88d18148c
fs/io/FileOutputStream: change #if to #ifdef
2016-08-16 07:49:30 +02:00
Max Kellermann
1cf43a9dc9
fs/io/FileOutputStream: add missing include
2016-08-16 07:49:01 +02:00
Max Kellermann
196ce8426b
fs/io/FileOutputStream: decouple from the FileSystem library
2016-08-15 22:42:44 +02:00
Max Kellermann
6a95c34a81
fs/io/FileOutputStream: use C++11 initializers
2016-08-15 22:34:53 +02:00
Max Kellermann
ea0e6d9824
fs/FileSystem: RemoveFile() throws exception on error
2016-08-15 22:25:15 +02:00
Max Kellermann
14d3da0e18
fs/FileSystem: remove unused FOpenModes
2016-08-15 22:21:34 +02:00
Max Kellermann
b6b8fb7d73
PlaylistFile: use TruncateFile()
...
As a side effect, "playlistclear" no longer creates a new playlist if
the given one doesn't yet exist.
2016-08-15 22:19:55 +02:00
Max Kellermann
2bca3cd247
fs/FileSystem: add TruncateFile()
2016-08-15 22:13:38 +02:00
Max Kellermann
22a353b8e3
event/SignalMonitor: fix obsolete nullptr check in SignalCallback()
2016-08-15 12:40:16 +02:00
Max Kellermann
743fa73a01
Merge branch 'v0.19.x'
2016-08-15 12:33:07 +02:00
Max Kellermann
a546bfe7d9
decoder/wildmidi: support libWildMidi 0.4
2016-08-15 10:08:35 +02:00
Max Kellermann
25deae6cc7
decoder/wildmidi: move code to wildmidi_output()
2016-08-15 10:07:08 +02:00
Nils Schneider
62000670e3
Support S24_P32/S32/FLOAT sample formats on Pulse
...
This is based on a patch from Ian Scott in 2014. It was never committed,
so I figured I'd fix the outstanding issue and resubmit it.
https://www.mail-archive.com/mpd-devel%40musicpd.org/msg00139.html
2016-08-15 10:02:29 +02:00
Max Kellermann
ac49043fbb
output/pulse: move variable declaration down
2016-08-15 10:02:22 +02:00
Jacob Vosmaer
4d6192adcd
Use a ScopeLock around condition.wait()
2016-08-07 15:47:21 +02:00
Jacob Vosmaer
9f1ada898e
Improve readability of frame completion loop
2016-08-07 14:15:55 +02:00
Jacob Vosmaer
5617521380
Must lock/unlock around wait
2016-08-06 15:25:58 +02:00
Jacob Vosmaer
9835a2545d
Do not assume two pops are enough
2016-08-06 15:19:10 +02:00
Jacob Vosmaer
c28cefeeb0
output/osx: wait-free render callback
...
Closes https://bugs.musicpd.org/view.php?id=4537 .
Removed the 'cancel' function because it violates 'single producer,
single consumer'.
2016-08-06 00:08:10 +02:00
Max Kellermann
afd5b750dc
release v0.19.18
...
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
iQIcBAABCAAGBQJXpMKjAAoJECNuiljG20USti8QAJC6Y/wnyBgE8bGGynhNKoIy
H5GQP9a3iFAiZ4ZBQ6jJAVMhRVzStxqTvYdU8ISbrE9Sw92i37ZaUwvbOcMGjN8G
vm3oTSsPaQKABuaeNo0vdWDKEUIjXIFzyXL31SnGVCkS3KMLFUcq5p4/9OaFtxiD
dMshfi8S+g5MLZf1xf6sviTwHTNQJYYMOEGDlq9E21UorwA5jN22dgYRiEoYAPrv
eOCO+N+N7N3VazIN+Y2L0cU3NtJpRvtv001UcfP0oSb12bysSepCCVc02sYQYIY6
W0LCjgzAbLX5nxyNDR75cjwPZlVDXhulesUVg/0uEEITdwmd8E3MtAxygsSTth6r
fNo6NThceoD10T/HgSCaU/vXOV5MNw3oVwc4Q/aoCoPryuNGeN9vDIro3+EaPdsW
6cfBMTYIU3iWpdNt+WI1mTf2aD4RvWWb0C7kgD6CF2QUm8aBRSHmQAnua0cWvlx9
SSMhG7p4FXrLAveuqaPfDItsQ9IA8oW9E6nxgD8W7eCHEo+fUa1D8Ymfjl7Qcldb
WdT2u38PmF7s/z+YwrFWTISwdDieYq/XC7xPibUYDJQzqBmBksB07sJUwVAO6xF2
YhVlHhhIhYajD4n0VCLuC2QzRgoLEhaNstlK/q01lGZbW4F9/dNuZ2Fe/O+yWsLH
ksxyC62N4oy10f8/PSp1
=48Tb
-----END PGP SIGNATURE-----
Merge tag 'v0.19.18'
release v0.19.18
2016-08-05 18:51:38 +02:00
Max Kellermann
d042ab87da
decoder/Thread: delete the InputStream on error
...
Fixes memory leak after stream failure. See
https://bugs.musicpd.org/view.php?id=4562
2016-08-05 18:15:30 +02:00
Max Kellermann
588303b78d
lib/nfs/Manager: add Compare(ManagedConnection, ManagedConnection)
...
Required for Boost 1.61, which uses that overload in a BOOST_ASSERT().
2016-08-05 18:06:07 +02:00
Max Kellermann
5834843b8a
decoder/ffmpeg: fix the AVCodecParameters API check
...
Turns out the libavcodec version numbers are not linear; the feature
was added in FFmpeg 3.1 commit 998e1b8, libavcodec 57.14.0; but FFmpeg
3.0 has version 57.48.101. Ouch!
2016-08-02 19:15:23 +02:00
Max Kellermann
2777a23672
Merge branch 'v0.19.x'
2016-07-29 20:25:59 +02:00
Max Kellermann
762f3afb9d
decoder/sidplay: allow building with libsidplayfp instead of libsidplay2
...
https://bugs.musicpd.org/view.php?id=4558
2016-07-29 19:32:21 +02:00
Max Kellermann
7fb2f15a1a
decoder/ffmpeg: check avformat_open_input() return value
2016-07-29 19:32:21 +02:00
Max Kellermann
7456dccd3a
decoder/ffmpeg: FfmpegOpenInput() returns Error
2016-07-29 19:32:21 +02:00
Max Kellermann
245f41bb7e
decoder/ffmpeg: fix endless recursion in FfmpegScanStream()
...
Was accidently added by commit cafc266e0
2016-07-29 19:32:21 +02:00
Max Kellermann
9bfb844cfa
decoder/sidplay: read the "date" tag
2016-07-29 17:47:08 +02:00
Max Kellermann
d790d3ba3c
decoder/sidplay: add GetInfoString()
2016-07-29 17:38:04 +02:00
Max Kellermann
c3dbc92766
decoder/sidplay: use SidTune::getStatus()
2016-07-29 17:31:34 +02:00
Max Kellermann
0bd25f1e17
decoder/sidplay: log detailed error message
2016-07-29 17:04:38 +02:00
Max Kellermann
a4cd7411e8
decoder/sidplay: remove unnecessary error check
...
The ReSIDBuilder constructor cannot fail.
2016-07-29 17:03:26 +02:00
Max Kellermann
bf276f6235
decoder/sidplay: use SidTune::getStatus()
2016-07-29 16:58:58 +02:00
Max Kellermann
071cacc9a4
decoder/sidplay: pass SidTuneMod to get_song_length()
...
Eliminate duplicate SidTune construction.
2016-07-29 14:56:05 +02:00
Max Kellermann
33f33323af
decoder/sidplay: simplify the SidDatabase::length() call
2016-07-29 14:55:58 +02:00
Max Kellermann
388fae2c47
decoder/sidplay: include cleanup
2016-07-29 14:55:28 +02:00
Max Kellermann
9f878b77e9
decoder/sidplay: use class SidDatabase
...
Remove our own songlength database parser.
2016-07-29 14:55:28 +02:00
Max Kellermann
a547d2aaba
decoder/sidplay: use config_param::GetBlockPath()
2016-07-29 14:55:28 +02:00
Max Kellermann
c013026821
decoder/sidplay: make "songlength_file" local
2016-07-29 14:55:28 +02:00
Max Kellermann
96b48a2404
decoder/sidplay: pass parsed path to get_song_length()
...
Eliminates duplicate ParseContainerPath() call.
2016-07-29 14:55:28 +02:00
Max Kellermann
9612975c2c
decoder/sidplay: merge get_container_name() and get_song_num()
2016-07-29 14:55:28 +02:00
Max Kellermann
41bfd45a2e
fs/Path: make IsAbsolute() const
2016-07-29 14:55:28 +02:00
Max Kellermann
bbdcbd1f08
fs/Path: add methods GetBase() and GetDirectoryName()
2016-07-29 14:55:28 +02:00
Max Kellermann
6b3c525a9d
db/update/ExcludeList: declare exclude_list_domain only if HAVE_GLIB
2016-07-29 14:55:28 +02:00
Max Kellermann
83aed7051c
output/shout: rename "encoding" to "encoder"
...
The user manual specifies "encoder", which is consistent with other
output plugins. "encoding" should be deprecated.
2016-07-29 10:52:03 +02:00
Max Kellermann
77c6e45e65
Compiler.h: require gcc 4.7 or newer
...
The ScopeExit library uses C++11 initializers, which gcc 4.6 does not
support. Let's kill support for this ancient incomplete C++11
compiler, nobody should be using it anymore.
2016-07-29 09:52:23 +02:00
Max Kellermann
8825393660
decoder/ffmpeg: use avcodec_alloc_context3()
...
This commit suppresses the remaining deprecation warnings with FFmpeg 3.1.
2016-07-29 09:20:36 +02:00
Max Kellermann
2b9246c6ad
decoder/ffmpeg: use avcodec_send_packet() and avcodec_receive_frame() on FFmpeg 3.1
2016-07-29 09:20:05 +02:00
Max Kellermann
a9edb4de28
decoder/ffmpeg: use AtScopeExit() for safe cleanup
2016-07-29 09:08:14 +02:00
Max Kellermann
a076ddf38c
util/ScopeExit: new utility library
...
Similar to boost::scope_exit, but fewer include dependencies.
2016-07-29 09:07:58 +02:00
Max Kellermann
0c809fbb40
Merge branch 'v0.19.x'
2016-07-29 09:00:20 +02:00
Max Kellermann
cafc266e0b
decoder/ffmpeg: merge avformat_close_input() calls
2016-07-28 20:38:07 +02:00
Max Kellermann
a3d020eff9
decoder/ffmpeg: use AVCodecParameters on FFmpeg 3.1
...
The AVCodecContext attribute is deprecated.
2016-07-28 19:50:25 +02:00
Max Kellermann
8412d94d05
decoder/ffmpeg: add GetCodecParameters()
...
Preparing for FFmpeg 3.1 support.
2016-07-28 19:49:47 +02:00
Max Kellermann
d1c5bb956a
decoder/ffmpeg: move code to IsAudio()
2016-07-28 19:49:45 +02:00
Max Kellermann
70986bc120
decoder/ffmpeg: move code to FfmpegSendFrame()
2016-07-28 19:49:18 +02:00
Max Kellermann
f31fe8b865
decoder/ffmpeg: include cleanup
2016-07-28 19:49:17 +02:00
Max Kellermann
142a9fe530
decoder/ffmpeg: move code to pcm/Interleave.cxx
2016-07-28 19:49:13 +02:00
Max Kellermann
4dd2ad9b27
decoder/ffmpeg: check for commands earlier
...
Improve initial seek by not reading/decoding the first frame before
checking for the seek command.
2016-07-28 19:48:27 +02:00
Max Kellermann
62f7375804
decoder/ffmpeg: simplify mpd_ffmpeg_open_input()
2016-07-28 19:48:25 +02:00
Max Kellermann
543296b5ba
decoder/ffmpeg: move code to lib/ffmpeg/Init.cxx
2016-07-28 19:48:22 +02:00
Max Kellermann
5fee130d00
decoder/ffmpeg: move code to lib/ffmpeg/LogCallback.cxx
2016-07-28 19:47:49 +02:00
Max Kellermann
073facea70
decoder/ffmpeg: remove obsolete comment
2016-07-28 19:47:47 +02:00
Max Kellermann
dbe3b6eee4
decoder/ffmpeg: convert enums to constexpr
2016-07-28 19:47:36 +02:00
Max Kellermann
df97049647
decoder/ffmpeg: move struct AvioStream to FfmpegIo.hxx
2016-07-28 19:47:31 +02:00
Max Kellermann
42c5f68362
decoder/ffmpeg: use AVStream::duration
...
Use the duration of the stream we're actually decoding - not the
"global" attribute AVFormatContext::duration which may differ.
2016-07-28 19:47:24 +02:00
Max Kellermann
cc19e760cf
decoder/ffmpeg: use more references
2016-07-28 19:45:22 +02:00
Max Kellermann
0ff22a16fa
decoder/ffmpeg: move code to lib/ffmpeg/Time.hxx
2016-07-28 19:45:11 +02:00
Max Kellermann
47360ec906
decoder/ffmpeg: use av_free() instead of av_freep()
2016-07-28 19:45:07 +02:00
Max Kellermann
087a9938d2
decoder/ffmpeg: add API documentation
2016-07-28 19:45:05 +02:00
Max Kellermann
26d8e41a6b
decoder/ffmpeg: copy_interleave_frame() returns ConstBuffer
2016-07-28 19:45:01 +02:00
Max Kellermann
750ae1d3f3
decoder/ffmpeg: copy_interleave_frame() returns Error
2016-07-28 19:44:42 +02:00
Max Kellermann
f8a9a7a108
decoder/ffmpeg: simplify ffmpeg_send_packet()
2016-07-28 19:44:39 +02:00
Max Kellermann
eb192137d6
decoder/ffmpeg: copy the AVPacket in ffmpeg_send_packet()
...
Revert commit 70495aad
by rewriting it. Turns out, in old FFmpeg
versions, copying the AVPacket is necessary.
2016-07-28 19:42:25 +02:00
Max Kellermann
c25b464f37
decoder/ffmpeg: move code to class FfmpegBuffer
2016-07-27 17:31:02 +02:00
Max Kellermann
710b48d410
decoder/ffmpeg: log detailed error message
2016-07-27 17:28:12 +02:00
Max Kellermann
5e77a8199d
decoder/ffmpeg: remove obsolete comment
2016-07-27 17:28:12 +02:00
Max Kellermann
6637db086b
decoder/ffmpeg: add "pure" attributes
2016-07-27 17:28:12 +02:00
Max Kellermann
a271a55da7
decoder/ffpmeg: make variables more local
2016-07-27 17:28:12 +02:00
Max Kellermann
6eeec6cbfa
decoder/ffpmeg: simplify ffmpeg_send_packet()
2016-07-27 17:22:13 +02:00
Max Kellermann
5e3f3b0400
decoder/ffpmeg: rename functions to CamelCase
2016-07-27 17:18:58 +02:00
Max Kellermann
923c402f69
decoder/ffmpeg: optimize ffmpeg_scan_dictionary()
...
Don't scan tag items if the handler doesn't implement the tag()
method.
2016-07-27 17:17:14 +02:00
Jacob Vosmaer
ad80acb22a
output/osx: remove incorrect memset behavior
...
In e068d62
I added code that zeros the remainder of the output buffer
if there are not enough input frames available. I have now learned
that we can signal to the caller of the render callback how much data
is in the output buffers. In practice, the input buffer is so large
that it does not matter so much how we handle input buffer underruns,
but I suppose that saying 'there is no data' is better than 'here is
some silence for you'.
2016-07-22 20:58:37 +02:00
Max Kellermann
bd8414f8ea
Merge branch 'osx-channelmap' of git://github.com/jacobvosmaer/MPD
2016-07-14 09:19:24 +02:00
Max Kellermann
44219d5e91
decoder/flac: refactor flac_convert() to class FlacPcmImport
2016-07-11 23:34:55 +02:00
Max Kellermann
b9de3270f6
decoder/flac: specialize "stereo" for all bit depths
2016-07-11 23:33:34 +02:00
Max Kellermann
590d6faeb0
decoder/flac: convert flac_convert_*() to templates
2016-07-11 23:27:57 +02:00
Max Kellermann
62e96e9a58
decoder/flac: pass number of frames to flac_convert()
2016-07-11 23:24:48 +02:00
Max Kellermann
1c818ef0a0
decoder/flac: improve warning message about unsupported bit depth
2016-07-11 23:13:33 +02:00
Max Kellermann
d6ce2e3671
decoder/flac: move functions into struct FlacDecoder
2016-07-11 23:11:22 +02:00
Max Kellermann
85b6a52662
decoder/flac: use C++11 initializers
2016-07-11 22:44:39 +02:00
Max Kellermann
0246082b9b
decoder/flac: move position code to FlacDecoder::GetDeltaPosition()
2016-07-11 22:38:26 +02:00
Max Kellermann
3b031c6ba5
decoder/flac: throw exception on FLAC__stream_decoder_new() failure
2016-07-11 22:38:03 +02:00
Max Kellermann
74740ca50b
decoder/flac: add class FlacStreamDecoder wrapping a FLAC__StreamDecoder*
2016-07-11 22:37:55 +02:00
Max Kellermann
631baa7120
decoder/flac: eliminate redundant FlacDecoder attributes
2016-07-11 22:37:52 +02:00
Max Kellermann
657d6edff7
decoder/flac: add FlacInput getter methods
2016-07-11 22:37:49 +02:00
Max Kellermann
737c5a9549
decoder/flac: rename struct flac_data to FlacDecoder
2016-07-11 22:37:46 +02:00
Jacob Vosmaer
4cd9abe632
output/osx channel_map feature
2016-07-09 18:29:35 +02:00
Max Kellermann
b67e7df38e
release v0.19.17
...
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
iQIcBAABCAAGBQJXgCv6AAoJECNuiljG20USR3cP/RALB4qlhecMo6H8VwZvfjiA
FHfhBKfdpHM3U3EEIZc1zxwHIdWk1yELtmx298vmJbWUifpYAYarXF5497tZf2XE
AVfhTltEJEd7xB5ZULnEScM1aHzMZm5HRcHwM1UqNCsXP7PT8fmpk7gw19pKOChT
h8V3+tpC403lCIcHcJGlkuzgZvKIZDs73g7a0+4GxD9XRAPwnMYRl3Cfd8QjKT/U
r67AcOwQlS6hWJFs0K1JjOQwfwbRq2YmuOmFJua6n8O6CI/7t4h3faSQ0V/5qjFd
k/pAMRtX6mz3mjVhZv4cuMy+QILWlxUNwLBIwtxSfbwcFKrN0vtIRG8O9622hTs2
+mvYiVboWABk6hnukiDAfki96jWYHlsCJR5oIK9DZ4nBe5RVp0r9Nq/ook2AW2it
6VgYIDBI5zS/blyJzXtzDVWEtSmLFxm21JSl+jHfWDtL6/rQGimdVOFkRw40oCBz
seYb5kIbilrg6xq1KiBMT+EWmXMf+q+3YWQsu01blXGYGPhpUqhIr0h/qUfWAqMs
fwIsoxsTrkQQjEWb6YWupPrdOLZ+kTAyaK+7v8B8JmzS/H3SohusMPUZKsQXl82s
5LJVLtVxB9WRRmpfSoYqfk7CkTHOktCzVmiHb/FYUYElS9VKmJYYU8XQ25snCoZ6
bYtERsH28q8rrpkWWEXP
=IXD5
-----END PGP SIGNATURE-----
Merge tag 'v0.19.17'
release v0.19.17
2016-07-09 00:46:09 +02:00
Max Kellermann
ab95027fc6
decoder/flac: suppress warning at end of stream
...
This is required if a stream ands without another chained FLAC file.
2016-07-08 23:19:47 +02:00
Max Kellermann
ed3bc4ab63
decoder/flac: move code to FlacInitAndDecode()
2016-07-08 23:03:49 +02:00
Max Kellermann
68064f1aa6
decoder/flac: move duplicate code to flac_data::Initialize()
2016-07-08 22:44:23 +02:00
Max Kellermann
475ac76a5f
decoder/flac: late "total_frames" initialization
2016-07-08 22:43:31 +02:00
Max Kellermann
79d4f8674c
decoder/flac: remove "duration" parameter from flac_decoder_initialize()
...
It's always 0.
2016-07-08 22:41:19 +02:00
Max Kellermann
e42eed4d4c
decoder/flac: remove pointless check
2016-07-08 22:41:19 +02:00
Max Kellermann
4a7042e847
decoder/flac: handle unknown duration correctly
...
If the duration is unknown, pass SignedSongTime::Negative(), as
documented for decoder_initialized().
2016-07-08 22:33:49 +02:00
Max Kellermann
7f36923eb4
decoder/flac: pass SignedSongTime to decoder_initialized()
2016-07-08 22:32:23 +02:00
Max Kellermann
2ca8d69126
decoder/flac: document flac_data::position
2016-07-08 22:20:16 +02:00
Max Kellermann
70367d70c8
decoder/flac: remove obsolete sub-song support
...
This is obsolete because it has been moved to the MPD core.
2016-07-08 21:59:30 +02:00
Jacob Vosmaer
e068d62ac6
output/osx rewrite render callback
2016-07-08 15:36:42 +02:00
Max Kellermann
e6389ff5a1
client/ClientRead: call Break() before Close()
...
Referencing the attribute "partition" is illegal after Close(),
because Close() deletes "this".
2016-07-07 13:54:04 +02:00
Max Kellermann
b46cf57d98
event/BufferedSocket: OnSocketReady() returns true after close
...
Fixes use-after-free bug (https://bugs.musicpd.org/view.php?id=4548 ).
2016-07-07 13:52:20 +02:00
Max Kellermann
6f59d71e07
decoder/API: check initial_seek_running in _check_cancel_read()
...
The "seeking" flag is not set for the initial seek, and so
decoder_read() could be canceled when another SEEK was emitted during
initial seek.
This fixes several seek problems, for example the one reported for the
FLAC decoder plugin:
https://bugs.musicpd.org/view.php?id=4552
2016-07-06 15:46:04 +02:00
Max Kellermann
f9130f42a2
decoder/flac: try to recover from seek error()
...
libFLAC API documentation suggests that FLAC__stream_decoder_flush()
should be called to recover from FLAC__STREAM_DECODER_SEEK_ERROR.
2016-07-05 19:29:56 +02:00
Max Kellermann
faf2eeaa99
decoder/flac: evaluate all possible FLAC__stream_decoder_get_state() values
...
Stop after all fatal errors. This fixes assertion failures in
libFLAC.
2016-07-05 19:27:40 +02:00
Max Kellermann
1c7de0b4ac
output/shout: remove pointless memset() call
2016-07-05 18:02:35 +02:00
Max Kellermann
58487e484f
filter/route: use PcmSilence()
2016-07-05 18:01:29 +02:00
Max Kellermann
104075f3e0
PlayerThread: use PcmSilence() in SendSilence()
...
No change for regular PCM, but DSD uses 0x69 now.
2016-07-05 18:01:29 +02:00
Max Kellermann
b8097eaf2e
pcm/Volume: move silence pattern to Silence.cxx
2016-07-05 17:52:53 +02:00
Max Kellermann
5eb0cbc887
PlayerThread: make chunk allocation error non-fatal in SendSilence()
...
Fixes abort after seeking on fast machines.
2016-07-05 17:44:45 +02:00
Max Kellermann
1a4a6f3807
filter/Observer: fix memory leak
2016-07-04 15:25:21 +02:00
Max Kellermann
a012b25335
filter/convert: fix no-op check
...
Commit 3a212412
changed the meaning of out_audio_format, but I forgot
to apply this to ConvertFilter::FilterPCM().
See https://bugs.musicpd.org/view.php?id=4551
2016-07-04 15:17:03 +02:00
Jacob Vosmaer
2fdbae3e1f
Remove braces
2016-07-03 16:45:23 +02:00
Jacob Vosmaer
87e06793c2
Get rid of GetMacOSStatusCommentString
2016-07-03 14:06:53 +02:00
Jacob Vosmaer
8cc451a2e2
Use error.Set instead of error.Format
2016-07-03 13:36:35 +02:00
Jacob Vosmaer
723c2c7fa9
Remove some debugging code
2016-07-03 13:18:44 +02:00
Jacob Vosmaer
4dd2c5cdd5
Convert device name from CFStringRef to char*
2016-07-03 12:59:19 +02:00
Jacob Vosmaer
bdc257b40e
Add debug statements
2016-07-02 23:44:21 +02:00
Jacob Vosmaer
4728f7c697
Use AudioComponent instead of Carbon Component
2016-07-02 23:35:44 +02:00
Max Kellermann
07228ff56a
tag/Id3Load: use offset_type instead of off_t
2016-07-02 14:00:52 +02:00
Max Kellermann
a61f153df7
system/Error: add missing include
2016-07-02 13:59:47 +02:00
Max Kellermann
34e91850d9
decoder/pcm: assume that audio/L16 is big-endian
...
See https://bugs.musicpd.org/view.php?id=4547
2016-07-01 21:34:56 +02:00
Max Kellermann
ba8e579e9b
pcm/Volume: use 0x69 to generate DSD silence
2016-07-01 21:22:21 +02:00
Max Kellermann
072e39c9cf
filter/ReplayGain: skip PcmVolume if a mixer is set
...
Previously, volume was applied twice: once by PcmVolume, and again by
the hardware mixer.
2016-07-01 21:17:52 +02:00
Max Kellermann
3a21241248
filter/FilterInternal: split class Filter, add class PreparedFilter
...
For easier state management inside filter plugins.
2016-07-01 21:04:24 +02:00
Max Kellermann
5c75096bcd
pcm/Volume: remove assert() from destructor
...
While this assert() was useful when we had to track the object's state
manually, there was no practical purpose other than verifying old
code, and it complicates our new C++ code.
2016-07-01 21:04:24 +02:00
Max Kellermann
a43b0f5253
mixer/software: move Filter management to the AudioOutput
2016-07-01 18:23:53 +02:00
Max Kellermann
d93271e86d
mixer/software: use C++11 initializers
2016-07-01 14:06:08 +02:00
Dimitris Papastamos
4a6df9f961
output/sndio: Remove unused attribute
...
The variable is actually used in this function.
2016-06-24 09:11:36 +02:00
Dimitris Papastamos
a43ae2369b
output/sndio: Add 24-bit 4-byte packed audio format support
2016-06-24 09:11:30 +02:00
Dimitris Papastamos
9a049de859
output/sndio: No need to use a loop in Play()
...
This is a left-over from the previous version of the code
that was retrying on EINTR.
2016-06-24 09:10:57 +02:00
Dimitris Papastamos
58b8398aa0
output/sndio: Use size_t instead of ssize_t
...
Some minor style fixes as well.
2016-06-23 11:11:42 +02:00
Max Kellermann
645751f680
output/Init: use C++11 initializers
2016-06-22 18:44:00 +02:00
Dimitris Papastamos
26c0924461
sndio: Eliminate remaining goto usage to conform to MPD style
2016-06-22 16:10:46 +02:00
Dimitris Papastamos
d4f801a8e9
sndio: Fix segmentation fault when audio card is removed
...
This can happen if you remove an external audio card or if you stop
sndiod(8) while playing a song.
sio_write() will retry internally if it fails with errno == EINTR
so no need to handle that.
2016-06-22 16:10:38 +02:00
Dimitris Papastamos
8406864963
sndio: Allow tweaking application buffer size
...
It defaults to 250 ms.
2016-06-22 16:09:57 +02:00
Max Kellermann
85ef034fd0
filter/ReplayGain: use C++11 initializers
2016-06-22 12:43:47 +02:00
Max Kellermann
59141f62bb
filter/route: use std::array
2016-06-22 12:24:55 +02:00
Dimitris Papastamos
d68cadba7b
sndio: No need to use a timer so get rid of it
2016-06-22 11:28:58 +02:00
Max Kellermann
1207fd1f16
output/sndio: remove unnecessary initialization
2016-06-22 11:01:37 +02:00
Dimitris Papastamos
8aa61e230c
sndio: Add option to select output device
2016-06-22 11:00:06 +02:00
Max Kellermann
2c7bda8a3b
output/sndio: define SIO_DEVANY if it is undefined
...
Fixes build failure on Debian Wheezy.
2016-06-22 10:58:44 +02:00
Dimitris Papastamos
d58c5dd398
sndio: Implement sndio_test_default_device()
2016-06-22 10:54:59 +02:00
Dimitris Papastamos
171da7a347
Add sndio output plugin
2016-06-22 08:44:47 +02:00
Max Kellermann
3fd70a769a
event/SignalMonitor: remove unused function SignalMonitorGetEventLoop
2016-06-20 10:48:34 +02:00
Max Kellermann
4280f84535
event/SignalMonitor: use BoundMethod instead of raw function pointer
2016-06-20 10:46:36 +02:00
Max Kellermann
c3d9c32615
util/BindMethod: add nullptr constructor and bool operator
2016-06-20 10:36:37 +02:00
Max Kellermann
a938b609b9
util/BindMethod: document the default constructor
2016-06-20 10:36:09 +02:00
Max Kellermann
d3c7fac606
thread/Thread: throw std::system_error on error
2016-06-17 19:11:20 +02:00
Max Kellermann
fea3f6cc72
thread/Thread: use C++11 initialisers
2016-06-17 19:11:19 +02:00
Max Kellermann
aee5966e1c
input/thread: use C++11 initialisers
2016-06-17 19:10:39 +02:00
Max Kellermann
95e53ac0a0
input/alsa: rebase on AsyncInputStream
...
Use the snd_pcm_t only in the IOThread, and reuse code that is
well-known to work.
2016-06-17 18:36:54 +02:00
Max Kellermann
5d11759f7d
input/async: use class DeferredCall
2016-06-17 18:31:58 +02:00
Max Kellermann
829616534e
event/DeferredCall: new class supposed to replace DeferredMonitor
...
Comes with a callback pointer instead of a virtual method, which
allows multiple instances in one class.
2016-06-17 18:26:29 +02:00
Max Kellermann
863f4d8366
util/BindMethod: new utility class for callbacks
...
Replaces the old BoundMethod template.
2016-06-17 18:20:19 +02:00
Max Kellermann
bdd0c3686d
input/async: use class HugeAllocation
2016-06-17 18:06:02 +02:00
Max Kellermann
91769d536d
util/HugeAllocator: add class HugeAllocation
2016-06-17 18:01:13 +02:00
Max Kellermann
9500343d85
util/HugeAllocator: add "noexcept"
2016-06-17 17:59:45 +02:00
Max Kellermann
ef053035d0
util/HugeAllocator: throw std::bad_alloc on error
2016-06-17 17:57:40 +02:00
Max Kellermann
8b903626c2
release v0.19.16
...
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
iQIcBAABCAAGBQJXXuZbAAoJECNuiljG20USSegP/1gYoDyp4vDDCcRBNZkr3hlE
VbFyEz06/chfUTCRWFxtM6ghVMzSpqv7I8wDA8zv22NTkForVWD3gjimtJqJ/R4w
aT7QMZJmJUIH0Uf+dRp98YRG7m5S1Y5JkKEYu4oxQOECxbNMPd+ilbb6wwr2pYZ/
k2ks+oyYtPgqtWlriIbJMwXOyQEfqNCJgzxUzC2U6idVALYpj+5aK+VTY4Nk1YXw
nLAu8TT40jNYFfss0bDYBzQbm/82m8Q9JIkmoOpX/3WaRaCjaVza7IvRKgDPZutJ
mmrtu5SJ+QgLQLaXvav84KwtXhDbJu4zEbC7tUL0LGSmzbpiiz2DSUJP2jQ0C6nS
wgcACFkHGBLOjKNbjDB1eUhS7ouzxTGgPlsMC89254R7XQP/5EV9H3Quxb48Bxq7
PuW6nNHytppfAIZP18X62oL8hpSgwK1zLe34jzayJlkGIg5O1he4FcJQykvlzrjm
fBvL+hX3TM9exfASQujNXVgxFGPmgb37bE2aQyxZunE1DltJWfHyOhdme9vCuEcB
acz8gR/jcp8OKe4RCEdD1g86CSW2wlMfKfnzuwPPhcw0L3kz6OYcjRr2oMae7uG0
/NFw+PcdHcVKXjiRoJsdCvtN+jRtJhCUn314IskgyKad/UNcELbo7WDBUqHC36Wg
ncM6Sis4oal4jPXJ2JoE
=6ee1
-----END PGP SIGNATURE-----
Merge tag 'v0.19.16'
release v0.19.16
2016-06-13 19:03:59 +02:00
Max Kellermann
4ecd325371
decoder/flac: log seek errors
2016-06-13 18:37:45 +02:00
Max Kellermann
021519f295
command/QueueCommands: eliminate duplicate code in handle_addid()
2016-06-13 18:28:03 +02:00
Max Kellermann
e83685d667
Merge branch 'addid-with-pos' of git://github.com/ewollesen/MPD
2016-06-13 18:27:21 +02:00
Eric Wollesen
81a198a76a
return id for "addid" with position
...
Previously the id was being returned only when a position wasn't
specified.
2016-06-13 10:14:20 -06:00
Max Kellermann
5771d67202
player/Thread: cancel outputs before seeking
...
.. instead of doing it after seeking. After seeking, the command had
no effect, because CheckDecoderStartup() waits for all outputs to
finish. This caused a very long delay while seeking and switching
songs (https://bugs.musicpd.org/view.php?id=4534 ).
2016-06-13 09:13:56 +02:00
Lazaros Koromilas
b2b7974ba0
util/WStringAPI: wcpcpy(3) is not yet supported on OpenBSD/NetBSD
...
Signed-off-by: Lazaros Koromilas <lostd@2f30.org>
2016-06-12 16:36:17 +02:00
Lazaros Koromilas
f59ca94416
net/Resolver: correct includes for gettaddrinfo(3)
...
Signed-off-by: Lazaros Koromilas <lostd@2f30.org>
2016-06-12 16:36:17 +02:00
Max Kellermann
22ff0d80ce
decoder/pcm: add MIME type "audio/x-mpd-float"
2016-06-10 23:06:21 +02:00
Max Kellermann
5a22a0c27d
decoder/pcm: implement RFC 2586 (audio/L16)
...
https://bugs.musicpd.org/view.php?id=4525
2016-06-10 22:52:35 +02:00
Max Kellermann
287ef181ba
util/MimeType: add ParseMimeTypeParameters()
2016-06-10 22:52:35 +02:00
Max Kellermann
92cdea123e
TagStream, decoder/Thread, ...: ignore MIME type parameters for matching plugins
2016-06-10 22:24:13 +02:00
Max Kellermann
e4c7e343c8
util/StringUtil: use CamelCase
2016-06-10 22:08:13 +02:00
Max Kellermann
2ee43c403c
decoder/vorbis: reimplement using class OggDecoder
...
Use libvorbis instead of libvorbisfile, which gives us more control
over the decoding process.
2016-05-14 12:31:12 +02:00
Max Kellermann
24fa3f5e7b
Revert "decoder/Thread: flush last chunk only on success"
...
This reverts commit 995cd95474
. It was
a bad idea because it caused assertion failures when a decoder plugin
aborted with an exception.
2016-05-14 12:31:12 +02:00
Max Kellermann
bbbda7f812
decoder/opus: move code to new class OggDecoder
...
Prepare to reuse the same code for a new Vorbis decoder plugin based
on libvorbis instead of libvorbisfile.
2016-05-14 11:31:31 +02:00
Max Kellermann
e958900380
decoder/vorbis: reimplement _scan_stream() with plain libvorbis
2016-05-14 10:52:52 +02:00
Max Kellermann
74926c1dd3
decoder/opus: move _scan_stream() code to OggReadPacket()
2016-05-14 10:39:53 +02:00
Max Kellermann
2654888782
decoder/OggFind: move to lib/xiph/
2016-05-14 10:34:05 +02:00
Max Kellermann
b5ecfb4c9a
decoder/opus: move code to class OggVisitor
2016-05-13 13:37:49 +02:00
Max Kellermann
07fa3764ef
lib/xiph/OggStreamState: add wrapper for ogg_stream_reset()
2016-05-13 13:37:45 +02:00
Max Kellermann
5acc77a163
decoder/opus: change return types to void
2016-05-13 13:24:32 +02:00
Max Kellermann
0709878b4c
decoder/API: add class StopDecoder
2016-05-13 13:23:24 +02:00
Max Kellermann
662e477028
decoder/opus: throw exceptions instead of returning DecoderCommand::STOP
2016-05-13 13:18:19 +02:00
Max Kellermann
b7b7c381ee
decoder/Thread: catch exceptions
...
Allow decoders to throw std::runtime_error.
2016-05-13 13:01:39 +02:00
Max Kellermann
995cd95474
decoder/Thread: flush last chunk only on success
2016-05-13 13:01:31 +02:00
Max Kellermann
fe8a13f76f
decoder/Thread: move code to DecoderUnlockedRunUri()
2016-05-13 13:00:40 +02:00
Max Kellermann
9252432bc0
decoder/opus: move OggSyncState into class MPDOpusDecoder
2016-05-13 12:25:30 +02:00
Max Kellermann
f057f6768f
decoder/opus: pass DecoderReader to constructor
2016-05-13 12:16:22 +02:00
Max Kellermann
806bf0be8d
decoder/Reader: add methods GetDecoder(), GetInputStream()
2016-05-13 11:27:06 +02:00
Max Kellermann
958506a108
decoder/Reader: change Decoder pointer to reference
2016-05-13 10:40:10 +02:00
Max Kellermann
e8fd771b91
decoder/opus: change Decoder pointers to references
2016-05-13 10:39:36 +02:00
Max Kellermann
fa4178fefa
decoder/opus: remove ogg_page parameter from constructor
...
Initialize the OggStreamState as soon as the first page is seen; no
special code needed in the caller.
2016-05-11 17:57:51 +02:00
Max Kellermann
1af59d31b9
decoder/opus: add method IsInitialized()
2016-05-11 17:27:26 +02:00
Max Kellermann
20758cef30
decoder/opus: make internal methods "private"
2016-05-11 17:27:02 +02:00
Max Kellermann
272938529d
decoder/opus: move everything into anonymous namespace
2016-05-11 17:25:43 +02:00
Max Kellermann
a67b7266ed
util/AllocatedString: work around bogus gcc6 warning
2016-05-11 17:10:15 +02:00
Max Kellermann
f26159a0e3
lib/xiph/OggUtil: move code into class OggSyncState
2016-05-09 16:29:04 +02:00
Max Kellermann
675e8667c2
lib/xiph/OggSyncState: remove unused method ExpectFirstPage()
2016-05-09 16:27:11 +02:00
Max Kellermann
a1a26b70bc
decoder/opus: make opus_serialno a local variable
2016-05-09 15:43:15 +02:00
Max Kellermann
34a7f86a07
decoder/opus: use class OggStreamState in _stream_decode()
2016-05-09 15:41:03 +02:00
Max Kellermann
e7311ac2f3
decoder/opus: use C++11 initializers
2016-05-09 15:41:01 +02:00
Max Kellermann
8d9ecc0c62
decoder/opus: make variables more local
2016-05-09 15:41:00 +02:00
Max Kellermann
f01b991108
decoder/opus: use class OggStreamState in _scan_stream()
2016-05-09 15:40:59 +02:00
Max Kellermann
f80736c3d7
lib/xiph/OggStreamState: add method GetSerialNo()
2016-05-09 15:40:50 +02:00
Max Kellermann
2c7f69cf85
lib/xiph/OggStreamState: add constructor with ogg_page
2016-05-09 15:38:29 +02:00
Max Kellermann
348ecc1118
lib/xiph/OggStreamState: add method PageIn()
2016-05-09 15:29:37 +02:00
Max Kellermann
a9678f0ae0
decoder/opus: fix minor typo
2016-05-09 15:00:04 +02:00
Max Kellermann
461f298d2c
lib/xiph/OggStream: remove obsolete class
2016-05-09 14:55:58 +02:00
Max Kellermann
068de7cf40
encoder/ogg: use class OggStreamState
2016-05-09 14:51:07 +02:00
Max Kellermann
d04eb87c4f
encoder/opus: divert to OggEncoder::Read()
2016-05-09 14:51:05 +02:00
Max Kellermann
8af68db965
lib/xiph/OggStreamState: new ogg_stream_state wrapper
2016-05-09 14:50:39 +02:00
Max Kellermann
1cf632e98b
lib/xiph/OggStream: move code to ReadPage()
2016-05-09 14:22:12 +02:00
Max Kellermann
58c11c3128
encoder/vorbis: move vorbis_info_init() call to constructor
2016-05-09 13:22:59 +02:00
Max Kellermann
efcda95dda
encoder/vorbis: remove vorbis_info_clear() calls from error code paths
...
The destructor will call this in any case.
2016-05-09 13:22:43 +02:00
Max Kellermann
80d2028bac
encoder/vorbis: merge Clear() into the destructor
2016-05-09 13:22:27 +02:00
Max Kellermann
215213fc2c
encoder/vorbis: add wrapper class for vorbis_comment
2016-05-09 12:22:22 +02:00
Max Kellermann
0998097253
encoder/{vorbis,opus}: move common code to class OggEncoder
2016-05-04 18:52:57 +02:00
Max Kellermann
b376536a3b
encoder/Interface: convert PreparedEncoder to abstract class
2016-05-04 18:32:52 +02:00
Max Kellermann
e7edc02647
encoder/Interface: move instance methods to abstract class
...
Rename struct Encoder to PreparedEncoder, and add a new (abstract)
class Encoder which represents one encoder instance.
2016-05-04 16:32:31 +02:00
Max Kellermann
69bf835059
encoder/vorbis: move code into the struct
2016-05-04 16:22:59 +02:00
Max Kellermann
b97ffddfe8
encoder/vorbis: use CamelCase
2016-05-04 16:21:47 +02:00
Max Kellermann
6407b7c591
output/recorder: use C++11 initializers
2016-05-04 15:18:57 +02:00
Max Kellermann
e14cd92d59
output/shout: use AudioOutputWrapper
2016-05-04 15:06:29 +02:00
Max Kellermann
73cadd1798
output/shout: dispose encoder in destructor
2016-05-04 15:05:48 +02:00
Max Kellermann
fb9840f1f8
output/shout: call shout_shutdown() in destructor
2016-05-04 15:03:55 +02:00
Max Kellermann
492aaa3375
output/shout: use C++11 initializers
2016-05-04 14:46:45 +02:00
Max Kellermann
33c5da700d
encoder/opus: move functions into the struct
2016-05-03 23:56:47 +02:00
Max Kellermann
48d3af7d9a
encoder/opus: use CamelCase
2016-05-03 23:53:42 +02:00
Max Kellermann
9b3470eabd
lib/xiph/OggStream: use C++11 initializer
2016-05-03 23:46:56 +02:00
Max Kellermann
86a505b4f3
lib/xiph/OggSyncState: disallow copying
2016-05-03 23:45:32 +02:00
Max Kellermann
ed6c6296eb
{de,en}coder/{vorbis,flac,opus}: move several libraries to lib/xiph/
2016-05-03 23:40:29 +02:00
Max Kellermann
7adbd00811
decoder/{vorbis,flac,opus}: move OggCodec.cxx to libxiph.a
2016-05-03 12:54:47 +02:00
Max Kellermann
1c91d19163
decoder/OggUtil: pass Reader instance to OggFeed()
2016-05-03 00:05:31 +02:00
Max Kellermann
f491135318
decoder/Reader: new Reader implementation
2016-05-03 00:05:31 +02:00
Max Kellermann
a7ced00520
input/Reader: new Reader implementation wrapping InputStream
2016-05-03 00:05:31 +02:00
Max Kellermann
280d35a053
decoder/api: use class ScopeLock
2016-05-02 23:33:08 +02:00
Max Kellermann
eca6b9f0af
thread/Mutex: add method ScopeLock::Unlock()
2016-05-02 23:32:44 +02:00
Max Kellermann
cc9345e703
encoder/wave: use CamelCase
2016-04-30 14:29:14 +02:00
Max Kellermann
3fb8f3ec95
release v0.19.15
...
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
iQIcBAABCAAGBQJXJKNhAAoJECNuiljG20US7pcP/A2sFmmf+QlKvV5G88D+UxbX
kIoz3d5mHRoW4kJcbhUKUVe9pIkQEWTVC4XNNi8ggO8/MUa7+FpUPR0bJDgmLnnm
jM3tV/eVXUmPgXTgj1PT0jOTNCNNJx69JYhz7nMGIAbxubs7hRGTfGgJYnTQImsW
yDVst0BH7C6i21kmAWjQYoFZu0h7ZoyBOZTHAyR/6wF6Bmlc5JAEV6eBRyrU3MLN
Mma4+rJhMh+2206SqUBJEVwEszaTJnmu7Xi5Zmk+LGSrykJt93bQio7k2hJ5PvKJ
feFCXl1IpobUMpPJ+Nv1QraTKO9lg5oEYOwlcxJf4JwfqpRk+oXr+MZ52iR9jMtw
otcux72CYMmSJOC2Sl8cq9TdQCOb7XxhDjv+Phf44WG5Ns1QJQY7rvrGLT0gFSLx
MVD2WKJCrWFgql6ugf9lhsrt7x8llD9anNqbJNamXmGoL0NFJs6sg9d02vbRuIDz
xOcBPKnDB/Ao1TxXT4/Ck6gzYwTd+sxvsrC2XwthDXTiM+qe+pAjF+KFKd5thIUs
Hh296GL8Ch68X+6HXVkCKwyW9F503LFAcXTlP6XQUnkpPHNU536VdUjaHmx557jR
3cY7d67gHSVxllDQJYp0GIMIKyaZhQ4V7w3l1IKzPc1KrhryOxvlbAaYVSHo26nI
yZMKwFJ1L0l9j76kZG4a
=GyO9
-----END PGP SIGNATURE-----
Merge tag 'v0.19.15'
release v0.19.15
2016-04-30 14:28:25 +02:00
Max Kellermann
c9553411bb
encoder/wave: add constant WAVE_FORMAT_PCM
2016-04-30 13:57:09 +02:00
Max Kellermann
62221adf55
encoder/wave: fix indent
2016-04-30 13:45:52 +02:00
Florian Schlichting
27d4b15925
DecoderBuffer: add missing include
...
> In file included from src/decoder/DecoderBuffer.cxx:21:0:
> src/decoder/DecoderBuffer.hxx:41:20: error: 'uint8_t' was not declared in this scope
> DynamicFifoBuffer<uint8_t> buffer;
> ^
> src/decoder/DecoderBuffer.hxx:41:27: error: template argument 1 is invalid
> DynamicFifoBuffer<uint8_t> buffer;
> ^
> src/decoder/DecoderBuffer.hxx: In member function 'void DecoderBuffer::Clear()':
> src/decoder/DecoderBuffer.hxx:61:10: error: request for member 'Clear' in '((DecoderBuffer*)this)->DecoderBuffer::buffer', which is of non-class type 'int'
> buffer.Clear();
> ^
> src/decoder/DecoderBuffer.hxx: In member function 'size_t DecoderBuffer::GetAvailable() const':
> src/decoder/DecoderBuffer.hxx:78:17: error: request for member 'GetAvailable' in '((const DecoderBuffer*)this)->DecoderBuffer::buffer', which is of non-class type 'const int'
> return buffer.GetAvailable();
> ^
> src/decoder/DecoderBuffer.hxx: In member function 'ConstBuffer<void> DecoderBuffer::Read() const':
> src/decoder/DecoderBuffer.hxx:87:19: error: request for member 'Read' in '((const DecoderBuffer*)this)->DecoderBuffer::buffer', which is of non-class type 'const int'
> auto r = buffer.Read();
> ^
> src/decoder/DecoderBuffer.hxx:88:27: error: could not convert '{<expression error>, <expression error>}' from '<brace-enclosed initializer list>' to 'ConstBuffer<void>'
> return { r.data, r.size };
> ^
> src/decoder/DecoderBuffer.hxx: In member function 'void DecoderBuffer::Consume(size_t)':
> src/decoder/DecoderBuffer.hxx:105:10: error: request for member 'Consume' in '((DecoderBuffer*)this)->DecoderBuffer::buffer', which is of non-class type 'int'
> buffer.Consume(nbytes);
> ^
This seems to be caused by a lacking include, fixed by the below patch.
I'm unsure what made this appear now, though, compiler and toolchain
libraries seem to be the same upstream versions that built 0.19.14-1
just fine in late March.
2016-04-25 08:30:27 +02:00
Max Kellermann
fc3e0dfcd1
fs/AllocatedPath: add method FromUTF8Throw()
2016-04-21 14:27:32 +02:00
Max Kellermann
6513ff92a7
fs/Charset: throw exception on error
2016-04-21 14:23:55 +02:00
Max Kellermann
a0eb6d0976
PlaylistFile: use the new AllocatedPath::FromFS() range overload
2016-04-21 14:22:59 +02:00
Max Kellermann
7530770842
fs/AllocatedPath: add FromFS() with pointer range
2016-04-21 14:21:24 +02:00
Max Kellermann
11ea72e240
fs/AllocatedPath: make constructor "explicit"
2016-04-21 14:20:56 +02:00
Max Kellermann
c98330909a
db/update/Walk: use AllocatedPath methods instead of PathTraitsFS
2016-04-21 14:15:01 +02:00
Max Kellermann
bec6fa4ad7
lib/icu/Converter: throw exception on error
2016-04-21 14:03:27 +02:00
Max Kellermann
ac7ce73526
player/Thread: cancel audio when decoder startup on seek fails
...
Fixes assertion failure in MultipleOutputs::Open() after seeking to a
failing song during playback.
2016-04-21 14:03:27 +02:00
Max Kellermann
4c6619e6c5
output/MultipleOutputs: use C++11 initializers
2016-04-21 13:28:31 +02:00
Max Kellermann
e8121fdc11
decoder/Thread: fail decoder_input_stream_open() if STOP is received
...
Fixes an assertion failure in tag_ape_scan() which is because
decoder_input_stream_open() returns an "unready" InputStream.
2016-04-21 13:15:34 +02:00
Max Kellermann
21f17270a1
lib/icu/Util: UCharFromUTF8() throws on error
2016-04-21 11:20:41 +02:00
Max Kellermann
423cd5900e
lib/icu/Util: fold UCharToUTF8Throw() into UCharToUTF8()
2016-04-21 10:58:21 +02:00
Max Kellermann
b9f535cd49
lib/icu/Win32: throw exception on error
2016-04-21 10:15:40 +02:00
Max Kellermann
c731a82b71
decoder/opus: limit the number of packets in _scan_stream()
2016-04-19 13:08:07 +02:00
Max Kellermann
e6fad97edc
decoder/opus: support bigger OpusTags packets
...
Required for OpusTags packets which contain artwork.
See https://bugs.musicpd.org/view.php?id=4520
2016-04-19 13:05:42 +02:00
Max Kellermann
e228144159
command/playlist: eliminate spl_print() calls
...
playlist_file_print() already handles stored playlists. spl_print()
is never called with a successful result.
2016-04-13 19:47:41 +02:00
Max Kellermann
9431a7b022
playlist/Any: fix documentation typo
2016-04-13 19:23:14 +02:00
Max Kellermann
cd041f8574
decoder/Plugin: container_scan() returns AllocatedString
2016-04-13 12:23:10 +02:00
Max Kellermann
8ba3378096
util/AllocatedString: add operator==(nullptr)
2016-04-13 12:23:10 +02:00
Max Kellermann
225984822d
lib/icu/Win32: use std::unique_ptr
2016-04-13 11:53:35 +02:00
Max Kellermann
01b68db30e
lib/icu/Converter: Create() throws exception on error
2016-04-13 10:04:19 +02:00
Max Kellermann
33fdaa5b6d
Merge branch 'v0.19.x'
2016-04-13 10:03:40 +02:00
Max Kellermann
70495aada1
decoder/ffmpeg: don't copy the AVPacket in ffmpeg_send_packet()
...
Reduce some overhead. It is not necessary to copy the object.
2016-04-13 09:04:51 +02:00
Max Kellermann
f243f615ef
decoder/ffmpeg: convert pointers to references
2016-04-13 09:01:54 +02:00
Max Kellermann
6a1f5667f9
util/FormatString: return AllocatedString
2016-04-12 22:59:23 +02:00
Max Kellermann
fab5f58ee0
util/AllocatedString: add operator[]
2016-04-12 22:57:13 +02:00
Max Kellermann
55be8e6f52
util/AllocatedString: add typedef size_type
2016-04-12 22:56:57 +02:00
Max Kellermann
c75b9b0d12
util/StringPointer: add typedef reference_type
2016-04-12 22:55:12 +02:00
Max Kellermann
9b85446808
util/StringPointer: rename typedef pointer to pointer_type
2016-04-12 22:53:06 +02:00
Max Kellermann
fd5d42836f
Client: add WriteString()
2016-04-12 22:32:38 +02:00
Max Kellermann
4eaa82fd22
lib/icu/Util: add overload which throws exception
2016-04-12 22:08:48 +02:00
Max Kellermann
a497cc46f9
lib/icu/Util: use std::unique_ptr
2016-04-12 22:07:23 +02:00
Max Kellermann
178f737971
lib/icu/Collate: use std::unique_ptr
2016-04-12 21:55:14 +02:00
Max Kellermann
74963bce9d
lib/icu/Collate: use class AllocatedArray
2016-04-12 21:55:14 +02:00
Max Kellermann
33a4dbe1e5
lib/icu/Util: use class AllocatedArray
2016-04-12 21:42:14 +02:00
Max Kellermann
60f32d0bce
util/AllocatedArray: new utility class
2016-04-12 21:32:56 +02:00
Max Kellermann
dce36d3e55
lib/icu/Util: remove obsolete documentation
2016-04-12 21:32:56 +02:00
Max Kellermann
807c72b2f1
decoder/ffmpeg: use av_packet_unref() instead of av_free_packet()
...
av_free_packet() was deprecated in FFmpeg 3.0.
2016-04-12 21:15:05 +02:00
Max Kellermann
4f393553f4
playlist/Song: catch SongLoader exceptions
...
Fixes aborted "load" commands due to SongLoader failure.
2016-04-12 21:09:53 +02:00
Max Kellermann
74dbaade6f
decoder/Thread: use "ffmpeg" as fallback instead of "mad"
...
Adds support for stream codecs which havn't been explicitly listed in
ffmpeg_mime_types.
2016-03-30 00:58:48 +02:00
Max Kellermann
2deb5b7fec
sticker/SongSticker: add missing <stdexcept> include
...
For std::runtime_error. See http://bugs.musicpd.org/view.php?id=4509
2016-03-30 00:35:25 +02:00
Max Kellermann
53677172f2
notify: use "constexpr" only with glibc
...
The Mutex and Cond constructors are only "constexpr" with glibc, and
this is what this #ifdef is about.
Backport of commit 459a812a
See http://bugs.musicpd.org/view.php?id=4511
2016-03-30 00:31:01 +02:00
Max Kellermann
2fd5182608
db/Interface: GetSong() throws exception on error
2016-03-19 00:19:50 +01:00
Max Kellermann
7ad7caa2ae
queue/PlaylistUpdate: extend catch clause
2016-03-19 00:19:47 +01:00
Max Kellermann
6d1710c74f
PlaylistPrint: catch Database::GetSong() exceptions
2016-03-19 00:16:01 +01:00
Max Kellermann
233b8d0129
sticker/Song: catch Database::GetSong() exceptions
2016-03-19 00:14:40 +01:00
Max Kellermann
f55bdf07d3
db/Interface: Open() throws exception on error
2016-03-19 00:05:11 +01:00
Max Kellermann
6c2b532ae3
db/proxy: throw exception on error
2016-03-19 00:02:50 +01:00
Max Kellermann
2539f294e4
db/proxy: move code to MakeError()
...
Use this function instead of CheckError() when we already know an
error has occurred.
2016-03-18 23:43:28 +01:00
Max Kellermann
b6a3ce9305
db/proxy: fix inconsistent error handling in VisitUniqueTags()
2016-03-18 23:42:04 +01:00
Max Kellermann
b07495aae9
db/proxy: remove superfluous CheckError() call
2016-03-18 23:41:24 +01:00
Max Kellermann
686a53215d
db/proxy: use AtScopeExit()
2016-03-18 23:10:42 +01:00
Max Kellermann
6fd7d8191e
db/simple: refactor Check() to throw exception
2016-03-18 22:21:09 +01:00
Max Kellermann
2ccd1cc9f0
db/simple: remove misplaced "pure" attribute
2016-03-18 22:18:09 +01:00
Max Kellermann
8167bdd978
db/simple: handle Database::Open() exceptions in Mount()
2016-03-18 18:55:54 +01:00
Max Kellermann
dfb3e34f7b
db/lazy: remove obsolete class
...
Obsoleted by commit d4d4d621
2016-03-18 18:48:27 +01:00
Max Kellermann
45ee75055e
db/upnp: remove obsolete code comment
2016-03-18 18:48:00 +01:00
Max Kellermann
5da4e321c0
Stats: catch exceptions
2016-03-18 18:46:43 +01:00
Max Kellermann
e8519fecb4
release v0.19.14
...
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
iQIcBAABCAAGBQJW7DpiAAoJECNuiljG20USwwkP/1z3HeJjzzrwySH9MVeFpVtR
fr9XL2pO6zTcaVAIk/fNWtrcT6G5IuK079GKVa2jADN8KRMfCvGDEgHfGevjRNmc
USXkUm2pij67S3Ic74WhDISt32gYzBOCo/nFIFncLyjXXPW4WRq/3rb8tMwffZen
d/wqZmzHGEom8z0BTLASY/QM2KTBXOHgAhTb4M8lowxlesK8O/6Mx14UxgcIKIDf
1lqRhaF6NRS56uwjt8GwkaH9Td8wJG/inVLQo08z26ycJNaPrkxSNrWsSzQdBr8Q
DanbH4nefj8L33PVCV9nNPSjGe5s3R3D9WVEvt+cJ71UqBUQJkYgXaYRLQVEs1Mk
80a9MlFECF1UiS9FwmnUXRAY0Zzb19NLjm+v3CeMANqoFQ/OQaIe3/iaM0hT0yto
akHWhgEE4SuwcHPpUXQlKlbYHW6DaHBULwpzcKxFUeQkzx5m4FshBSL73TEEyv8+
bRc4tGIqA2Pep/Ptg3R9mJZ5wr/crtJby9FxNUkXiGZeiHEya+mRdGVyogMnce/K
BTg1bhiaE7Ofdxd4NuUIOZ6OkjpFnnQajJwnR1dJrZG+avOrGjcBPH5QGHWEYfs7
hVQhea2ehbcqQPq5celaZkL30SCxZmuN/0Lbmc8y7tpshLkdSUxmBoPSjvUD/UUz
JyZf+npL5nmtF0Pqz7W8
=McwP
-----END PGP SIGNATURE-----
Merge tag 'v0.19.14'
release v0.19.14
2016-03-18 18:41:14 +01:00
Max Kellermann
06c172838c
queue/PlaylistUpdate: catch and ignore DatabaseError
...
Fixes regression by commit 42f7df96
2016-03-18 18:25:16 +01:00
Max Kellermann
1543dd85b5
queue/Playlist: don't let StaleSong() interrupt playback
...
http://bugs.musicpd.org/view.php?id=4470
2016-03-18 18:08:13 +01:00
Max Kellermann
f37a1026f9
queue/Playlist: rename DeleteSong() to StaleSong()
2016-03-18 18:01:01 +01:00
Max Kellermann
91fb7fa3d8
queue/Playlist: pass unsigned to PlayOrder()
2016-03-18 17:49:29 +01:00
Max Kellermann
7b70153068
queue/Playlist: document that current/queued are "order number"
2016-03-18 17:35:29 +01:00
Max Kellermann
7e096ee2c5
db/update/Remove: update code comment
2016-03-18 16:58:06 +01:00
Max Kellermann
86a90daf1b
db/update/Remove: pass URI to Remove()
2016-03-18 16:57:43 +01:00
Max Kellermann
42f7df9681
db/update/Remove: reimplement as a non-blocking queue
...
This reduces overhead for two reasons:
1. calls to Remove() are non-blocking
2. RunDeferred() may work on large chunks at a time, reducing the
number of RunDeferred() calls
2016-03-18 16:43:02 +01:00
Max Kellermann
2edad38c7c
db/DatabaseListener: pass URI to OnDatabaseSongRemoved()
...
There's no point in passing a LightSong reference here; the callee is
interested only in the URI.
2016-03-18 16:22:33 +01:00
Max Kellermann
296ee4961e
sticker/Song: add _delete() overload with "const char *"
2016-03-18 16:21:26 +01:00
Max Kellermann
b1becddf11
util/StringView: add method Strip()
2016-03-18 15:40:49 +01:00
Max Kellermann
667edcd9d0
util/IterableSplitString: cheaper variant of SplitString()
2016-03-18 14:11:50 +01:00
Max Kellermann
b4e75bedf0
util/StringView: make nullptr_t constructor "constexpr"
2016-03-18 14:11:50 +01:00
Max Kellermann
5482ef5451
util/SplitString: relicense to BSD-2
2016-03-18 13:18:31 +01:00
Max Kellermann
a3afd5178c
tag/TagPool: optimize _dup_item()
...
When a reference counter is at its limit, don't allocate a new
TagPoolSlot - that would result in many TagPoolSlot instances with
ref==1. This in turn would make the linked list very very large,
which means quadratic runtime for many operations.
2016-03-14 13:08:04 +01:00
Max Kellermann
f1285a6dfd
tag/TagPool: add constexpr MAX_REF
2016-03-14 08:07:22 +01:00
Max Kellermann
cf7c1afb93
tag/TagPool: use prime number for NUM_SLOTS
2016-03-14 08:04:51 +01:00
Max Kellermann
f254831aa6
Instance: remove redundant "virtual" keywords
2016-03-10 23:16:35 +01:00
Max Kellermann
bd40c8649c
Partition: use Instance::EmitIdle()
2016-03-10 23:12:03 +01:00
Max Kellermann
7c53df2ed1
Partition: eliminate GlobalEvents.hxx, add mask constants
2016-03-10 23:10:14 +01:00
Max Kellermann
5ca6026787
Partition: use CallbackMaskMonitor, replacing class GlobalEvents::Monitor
2016-03-10 22:52:16 +01:00
Max Kellermann
483daa5882
Instance: move GlobalEvents::Monitor to Partition
...
All remaining events are specific to the Partition.
2016-03-10 22:47:47 +01:00
Max Kellermann
e2bc92d128
Instance: replace IdleMaskMonitor with CallMaskMonitor
2016-03-10 22:38:10 +01:00
Max Kellermann
5ffe3773d4
event/MaskMonitor: add variant with bound method
2016-03-10 22:37:33 +01:00
Max Kellermann
a7c68018a2
util/Callback: new utility class for callback functions
2016-03-10 20:42:19 +01:00
Max Kellermann
5ffb82993e
IdleMonitor: new class to replace GlobalEvents::IDLE
...
Use MaskMonitor to eliminate duplicate code.
2016-03-10 20:32:43 +01:00
Max Kellermann
07add0bd91
Instance: add base class which owns the EventLoop
2016-03-10 20:32:35 +01:00
Max Kellermann
9a9b6fa326
queue/Playlist: add interface QueueListener, replacing calls to idle_add()
2016-03-10 20:10:14 +01:00
Max Kellermann
ba43ec5759
queue/Playlist: remove redundant "struct" keyword
2016-03-10 20:03:45 +01:00
Max Kellermann
008a9560fe
queue/Playlist: call OnModified(), eliminate duplicate code
2016-03-10 20:03:01 +01:00
Max Kellermann
6ff01cc72c
Merge branch 'v0.19.x'
2016-03-07 14:30:43 +01:00
Max Kellermann
e140a28073
archive/iso9660: check path buffer bounds
2016-03-07 14:21:01 +01:00
Max Kellermann
de61c3b962
archive/iso9660: use a single path buffer for Visit()
...
Avoid wasting 4 kB stack per directory level.
2016-03-07 14:01:52 +01:00
Max Kellermann
c46fc4531b
archive/iso9660: move the "." and ".." checks up
2016-03-07 14:01:40 +01:00
Max Kellermann
065a9ed10f
archive/iso9660: add local variable "filename"
2016-03-07 13:57:07 +01:00
Max Kellermann
e44c0254f7
archive/iso9660: make variables more local
2016-03-07 13:15:07 +01:00
Max Kellermann
13f9f0315f
util/HugeAllocator: fix division by zero due to inverted check
...
There were two ways this could fail:
1. division by zero when sysconf(_SC_PAGESIZE)==0
2. mmap() failure because the size parameter is not aligned to page
size
Neither ever happened: sysconf() never fails, and the only caller
passes a size that is already aligned. Phew.
2016-03-06 23:53:41 +01:00
Max Kellermann
1532ffe215
protocol/ArgParser: fix range check
...
The old check
unsigned(value) > std::numeric_limits<unsigned>::max()
.. cannot ever fail.
2016-03-06 23:41:08 +01:00
Max Kellermann
b24cbc68ba
decoder/dsdiff: fix off-by-one buffer overflow
2016-03-06 23:28:29 +01:00
Max Kellermann
976fdd76c1
decoder/opus: limit tag size to 64 kB
2016-03-06 23:26:48 +01:00
Max Kellermann
bbda335e02
mixer/pulse: fix integer division rounding
2016-03-06 23:23:30 +01:00
Max Kellermann
031410c72b
Instance: add StateFile* attribute
2016-03-05 21:00:38 +01:00
Max Kellermann
710def8e38
Partition: un-inline the constructor
2016-03-05 20:51:29 +01:00
Max Kellermann
c0bda1b103
Idle: move flags to IdleFlags.hxx
2016-03-05 20:48:37 +01:00
Max Kellermann
0e87ce4680
GlobalEvents: expose the internal class
...
Move the GlobalEvents::Monitor instance into class Instance.
Eliminate all global variables.
2016-03-05 20:23:30 +01:00
Max Kellermann
b4d594eeff
Instance: embed EventLoop, no pointer
2016-03-05 20:20:12 +01:00
Max Kellermann
ce09379bae
Main: use Instance::Shutdown()
2016-03-05 20:20:12 +01:00
Max Kellermann
b27fb64317
client/ClientRead: use Instance::Shutdown()
2016-03-05 20:19:20 +01:00
Max Kellermann
099455db25
db/update/Service: convert const to constexpr
2016-03-05 20:08:01 +01:00
Max Kellermann
3146bf51e6
db/update/Service: eliminate attribute "progress"
...
Use walk!=nullptr instead.
2016-03-05 19:40:11 +01:00
Max Kellermann
b24a5e0662
Partition: add method EmitIdle()
...
Prepare for moving idle events to class Partition. Right now, it's
just a wrapper for idle_add().
2016-03-05 19:16:39 +01:00
Max Kellermann
e52ac0b187
event/MaskMonitor: new class to replace code in GlobalEvents and Idle
2016-03-05 19:15:50 +01:00
Max Kellermann
eaa1590866
GlobalEvents: eliminate SHUTDOWN, use Instance::Shutdown() instead
2016-03-05 18:56:27 +01:00
Max Kellermann
071af004bd
GlobalEvents: include cleanup
2016-03-05 18:56:27 +01:00
Max Kellermann
23ab4e5e5f
Instance: add method Shutdown()
2016-03-05 18:56:16 +01:00
Max Kellermann
8e563cbccd
Instance: use C++11 initializers
2016-03-05 18:55:57 +01:00
Max Kellermann
1aee89f5ea
*: include cleanup (using iwyu)
2016-03-01 22:08:13 +01:00
Max Kellermann
d2dd6f7c70
thread/Posix{Mutex,Cond}: use "constexpr" only with glibc
...
Apparently all other C libraries are not compatible with "constexpr".
Those which are not will get a performance penalty, but at least they
work at all.
2016-03-01 21:23:59 +01:00
Max Kellermann
fb547260d1
player/Control: Play*() returns Error information
2016-02-28 13:31:41 +01:00
Max Kellermann
2065e32904
queue/PlaylistControl: clear "queued" before calling LockSeek()
...
This is necessary to avoid an assertion failure in UpdateQueuedSong()
after LockSeek() has failed.
2016-02-28 13:19:44 +01:00
Max Kellermann
ac15581c56
command/error: remove unused function print_playlist_result()
2016-02-28 11:53:38 +01:00
Max Kellermann
9e2e882157
PlaylistPrint: throw PlaylistError on error
2016-02-28 11:52:39 +01:00
Max Kellermann
99ded56047
command/error: remove db_domain from ToAck(Error)
2016-02-28 11:48:12 +01:00
Max Kellermann
65386f52f0
db/proxy: throw DatabaseError on error
2016-02-28 11:47:03 +01:00
Max Kellermann
5b8dce7456
db/simple: throw DatabaseError on error
2016-02-28 11:40:59 +01:00
Max Kellermann
de938eb621
db/simple: handle exception in Open() properly, fix memory leak
2016-02-28 11:40:39 +01:00
Max Kellermann
83cc6c0835
db/simple: use second Error instance in Open()
...
Don't need to clear the caller-specified one.
2016-02-28 11:38:22 +01:00
Max Kellermann
304d78a4c8
command/error: remove playlist_domain from ToAck(Error)
...
playlist_domain is no longer used for class Error.
2016-02-28 11:17:43 +01:00
Max Kellermann
347590751c
SongLoader: throw PlaylistError on error
2016-02-28 11:15:20 +01:00
Max Kellermann
fe4b1f96f1
SongLoader: use temporary stack variable, no heap allocation
...
Improved exception-safety.
2016-02-28 11:08:00 +01:00
Max Kellermann
9de984f7f8
queue/PlaylistControl: throw PlaylistError on error
2016-02-28 11:04:35 +01:00
Max Kellermann
b6cb9b853a
queue/PlaylistEdit: throw PlaylistError on error
2016-02-28 11:02:36 +01:00
Max Kellermann
50b930f283
playlist/edit: use std::unique_ptr
2016-02-28 11:00:59 +01:00
Max Kellermann
cbeb809798
playlist/queue: use std::unique_ptr
2016-02-28 10:58:50 +01:00
Max Kellermann
ea626368a0
queue/QueueCommands: use std::unique_ptr
2016-02-28 10:56:37 +01:00
Max Kellermann
c81747dd15
queue/PlaylistTag: throw PlaylistError on error
2016-02-28 10:40:31 +01:00
Max Kellermann
f8810d7caf
PlaylistError: add NotPlaying()
2016-02-28 10:38:17 +01:00
Max Kellermann
92f54f0b59
output/alsa: disable DoP if it fails
...
See http://bugs.musicpd.org/view.php?id=4496
2016-02-28 10:19:19 +01:00
Max Kellermann
ddce544b53
output/alsa: move the PcmExport::Open() call to Open()
2016-02-28 10:15:54 +01:00
Max Kellermann
21fb7eea82
output/alsa: probe DSD_U32 if DSD_U8 fails
...
See http://bugs.musicpd.org/view.php?id=4485
2016-02-28 09:59:09 +01:00
Max Kellermann
fd7eb43366
output/alsa: use CamelCase
2016-02-28 09:44:15 +01:00
Max Kellermann
a1add27c4c
output/alsa: fix indent
2016-02-28 09:35:57 +01:00
Max Kellermann
fc8194ee1e
output/alsa: fix typo
2016-02-28 09:35:55 +01:00
Max Kellermann
8ffcdb73e8
output/alsa: remove option "use_mmap"
...
MPD does not really take advantage of memory-mapped I/O by generating
data right into the ALSA buffer; using plain snd_pcm_mmap_writei() has
no advantage compared to snd_pcm_writei(). Let's kill this
non-feature.
2016-02-28 09:30:59 +01:00
Max Kellermann
111528e51c
output/alsa: add #ifdef ENABLE_DSD
...
Fixes the --disable-dsd build.
See http://bugs.musicpd.org/view.php?id=4498
2016-02-28 07:29:37 +01:00
Max Kellermann
5628dcf47e
pcm/export: add #ifdef ENABLE_DSD to struct Params
2016-02-27 08:02:01 +01:00
Max Kellermann
fb4f02cd38
pcm/PcmExport: add flag to export to DSD_U32
2016-02-27 07:42:09 +01:00
Max Kellermann
d1be643c0d
pcm/PcmDsd: add converter from DSD_U8 to DSD_U32
2016-02-27 07:41:58 +01:00
Max Kellermann
c9761bf6af
output/alsa: pass PcmExport::Params to alsa_setup()
2016-02-27 07:35:35 +01:00
Max Kellermann
4a47265224
output/alsa: pass PcmExport::Params to SetupDop()
2016-02-27 07:34:58 +01:00
Max Kellermann
f0f3017a76
pcm/export: move Open() parameters to struct Params
2016-02-26 18:55:27 +01:00
Max Kellermann
d3f0b62348
pcm/export: another #ifdef ENABLE_DSD fix
2016-02-26 18:55:06 +01:00
Max Kellermann
6a53fb33da
output/alsa: basic infrastructure for DSD_U16 and DSD_U32
2016-02-26 18:44:58 +01:00
Max Kellermann
dcaf299864
pcm/export: add #ifdef ENABLE_DSD
2016-02-26 18:44:23 +01:00
Max Kellermann
1d67aa7bf2
update copyright year to 2016
2016-02-26 17:54:05 +01:00
Max Kellermann
e56066f721
pcm/dsd: use PcmBuffer::GetT()
2016-02-26 17:41:18 +01:00
Max Kellermann
5e3844ac13
pcm/dsd: use MAX_CHANNELS
2016-02-26 17:41:06 +01:00
Max Kellermann
cb4f5d454b
pcm/dsd: use std::array
2016-02-26 17:38:46 +01:00
Max Kellermann
e5c6fe1bb2
player/control: unpause in Play()
...
Fix regression by commit 45f6129a
See http://bugs.musicpd.org/view.php?id=4477
2016-02-26 17:33:21 +01:00
Max Kellermann
bf65a9732c
decoder/thread: clear Decoder::error before attempting another plugin
...
Keep only the last error. This fixes bogus aborts due to the error
check in decoder_get_virtual_command().
2016-02-26 17:30:24 +01:00
Max Kellermann
1388b3219a
decoder/thread: fix typo in comment
2016-02-26 16:48:27 +01:00
Max Kellermann
d9e8ce22cb
util/Error: use std::exception_ptr instead of std::exception
...
Necessary to preserve type information. The try/catch sequence didn't
work previously.
Same fix as in commit 1c904000
2016-02-26 16:32:24 +01:00
Max Kellermann
224944528f
TagArchive: include cleanup
2016-02-26 15:10:33 +01:00
Max Kellermann
cdcd3e77b3
TagArchive: refactor TagHandler overload to use ArchiveFile
2016-02-26 15:07:30 +01:00
Max Kellermann
ed5058a363
TagArchive: remove obsolete overload
2016-02-26 15:07:00 +01:00
Max Kellermann
a670ff6d3e
SongUpdate: remove obsolete overload UpdateFileInArchive(Storage)
2016-02-26 15:06:16 +01:00
Max Kellermann
32f6d34904
db/update/Archive: rescan tags on existing songs in archive
...
This is the final piece for full ID3/APE support in archives.
2016-02-26 15:05:49 +01:00
Max Kellermann
d3ae05506d
SongUpdate: remove archive handling from LoadFile()
...
This code has been moved to LoadFromArchive().
2016-02-26 15:05:44 +01:00
Max Kellermann
96f4394dce
db/update/Archive: pass ArchiveFile to Song constructor
...
Don't open the ZIP file again and again for each song file.
2016-02-26 15:05:40 +01:00
Max Kellermann
35567e6507
SongUpdate: add UpdateFileInArchive(ArchiveFile&)
2016-02-26 14:53:37 +01:00
Max Kellermann
ae37e25452
TagArchive: add overload with ArchiveFile&
2016-02-26 14:46:01 +01:00
Max Kellermann
c4537fe6f6
TagArchive: add TagBuilder overload with ScanGenericTags() fallback
...
Load APE/ID3 tags from archives.
2016-02-26 14:03:16 +01:00
Max Kellermann
677334f5a9
tag/TagId3: re-add missing tag_id3_load()==nullptr check
2016-02-26 14:00:30 +01:00
Max Kellermann
3d9652ae35
TagStream: add TagBuilder overload with ScanGenericTags() fallback
...
This commit adds support for APE/ID3 tags from NFS/SMB files.
See http://bugs.musicpd.org/view.php?id=4270
2016-02-26 13:48:38 +01:00
Max Kellermann
a9130cb99c
TagFile: add TagBuilder overload with ScanGenericTags() fallback
2016-02-26 13:48:38 +01:00
Max Kellermann
b1d60b5c85
TagArchive: use InputStreamPtr
2016-02-26 13:48:38 +01:00
Max Kellermann
99a05c56ad
tag/Generic: use InputStream::LockRewind() instead of Rewind()
...
Fixes deadlock.
2016-02-26 13:48:38 +01:00
Max Kellermann
cfc65397b3
tag/Generic: clarify documentation on InputStream overload
2016-02-24 00:01:51 +01:00
Max Kellermann
cd8fd1ef42
tag/Generic: remove redundant documentation
2016-02-24 00:01:30 +01:00
Max Kellermann
6350089e51
release v0.19.13
...
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
iQIcBAABCAAGBQJWzMnGAAoJECNuiljG20US5yYP/jL9A313aMgUO/R8eVGNc7uJ
CwiKROtgd+M47si1qdduzdrPKrFK2tEGYT0El5uQsyDuIsmPB01c3ZqnlM8oO6ca
5tXXJiEvyMkupCEzAajTHqvDCyPx0+o1ektYm9SouAULjOMztIpsVU3oKc8Z78Yc
TkpaRwUjNaekGLf0kATesBYnWkKR7S/TLYKmaKUaPCcK/i2S8YhTC57a1yZjg3lE
w57Kh+tFLZCSiZChk9A5D6w1kKzDgiyNGRYK4F2TRfiQ6hML4F45EFgzfCg+zHi8
+OIE9C1ZQt/NQ6mib+OUWoGuHtfjR20F/OFnQEYvkyXQ32j1sbALe7IHCceX7IHl
U88hcIh2yEr1x3TUaVyYPLze4FBq/Uxv/gFH8FVKTWmcb90MJgXCNFbO3sfO9kk0
KYK0IDoHE9MSmWhblA1FFFHU8VmCMsTN0VhBan+XP2wgXnGX+UvjU7AWJm4Fkwx0
H8uP0Si5wtI9DZ+2SRyGhMfW/+pHsqD+O6PoSSfUyU3ZnPy+cAVEC+67oKJ9pZkA
najeYaMt0Kz88RvLEwNeLkiys62O8aTsBpfjeNfmUAISJzZZbIvC20tyroHrju30
TgbXff2Hnx4q+NQ7nbQN5HMVZ2JLLPMYYw+N0dP41g/ULubHS6btGOVwgTWoFwBo
i2L1uscoD1ONxIEOlIvl
=X7s3
-----END PGP SIGNATURE-----
Merge tag 'v0.19.13'
release v0.19.13
2016-02-23 22:13:43 +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
Max Kellermann
8e5a67ed9f
tag/TagId3: eliminate dummy function when libid3tag is disabled
2016-02-23 11:16:19 +01:00
Max Kellermann
cccbcf510a
tag/{Id3,Ape}: remove Path overloads
2016-02-23 11:14:27 +01:00
Max Kellermann
a1e680fec7
decoder/thread: open InputStream in decoder_run_file() in any case
...
decoder_load_replay_gain() will create the InputStream anyway, so
we're not saving any overhead by opening the InputStream on demand
only.
2016-02-23 11:14:12 +01:00
Max Kellermann
1b58bd64ff
decoder/thread: use typedef InputStreamPtr
2016-02-23 11:14:11 +01:00
Max Kellermann
196de8c758
decoder/thread: load APE replay gain from remote files
2016-02-23 10:57:03 +01:00
Max Kellermann
222b777552
tag/ApeReplayGain: add overload with InputStream& parameter
2016-02-23 10:42:41 +01:00
Max Kellermann
b5c206d3ae
tag/Generic: use common InputStream for APE and ID3
2016-02-23 10:27:31 +01:00
Max Kellermann
17ace95268
tag/Generic: add overload with InputStream& parameter
2016-02-23 10:18:07 +01:00
Max Kellermann
779d73f94b
tag/TagId3: add overload with InputStream& parameter
2016-02-23 10:15:38 +01:00
Max Kellermann
73307bf2e7
tag/TagHandler: pass by reference
2016-02-23 10:10:13 +01:00
Max Kellermann
7623c1c5cb
SongUpdate: move tag_scan_fallback() to tag/Generic.cxx
2016-02-22 18:00:49 +01:00
Max Kellermann
de568c84c2
tag/ApeLoader: use CamelCase
2016-02-22 17:53:06 +01:00
Max Kellermann
1f5b9c6185
tag/ApeLoader: use std::unique_ptr
2016-02-22 17:50:15 +01:00
Max Kellermann
a5f8fd774d
tag/handler: use CamelCase
2016-02-22 17:38:06 +01:00
Max Kellermann
cc5443c38e
tag/ApeLoader: use class InputStream instead of FILE*
...
Prepare for APE tag support on userspace NFS/SMB/CIFS mounts.
2016-02-22 17:30:36 +01:00
Max Kellermann
8a86460b8f
tag/Id3Load: use class InputStream instead of FILE*
...
Prepare for ID3 support on userspace NFS/SMB/CIFS mounts.
2016-02-22 17:30:36 +01:00
Max Kellermann
7ae9e49f51
playlist/Stream, db/upnp: add missing includes
2016-02-22 17:30:36 +01:00
Max Kellermann
c682d087d9
tag/Id3Load: optimized ID3v1 loader
...
Use a 128 byte buffer instead of reading 10 bytes first and then 118.
2016-02-22 13:14:38 +01:00
Max Kellermann
57da5c0841
tag/Id3Load: simplify end offset calculation
2016-02-22 13:14:37 +01:00
Max Kellermann
a224722ae2
tag/Id3Load: add constant ID3V1_SIZE
2016-02-22 13:14:36 +01:00
Max Kellermann
283ef5b163
tag/Id3Load: use ID3_TAG_QUERYSIZE instead of integer literal
2016-02-22 13:14:35 +01:00
Max Kellermann
09a188bfd9
input/InputStream: add method Skip()
2016-02-22 13:14:19 +01:00
Max Kellermann
10f086854b
tag/Id3Load: remove unnecessary seek
2016-02-21 13:34:16 +01:00
Max Kellermann
d67c6c37e3
archive/bzip2: remove HAVE_OLDER_BZIP2 check
...
The check was added in commit 98fd9b7d
, but there was never a
definition.
2016-02-21 13:19:00 +01:00
Max Kellermann
136725dfb1
archive/bzip2: convert struct to class
2016-02-21 13:18:25 +01:00
Max Kellermann
438895842c
archive/bzip2: move bz2_fillbuffer into struct Bzip2InputStream
2016-02-21 13:17:22 +01:00
Max Kellermann
82b8f4f1ce
archive/bzip2: use C++11 initializer
2016-02-21 13:16:27 +01:00
Max Kellermann
0705f42cf8
playlist/Plugin: pass InputStreamPtr&& to open_stream()
...
Obsolete class CloseSongEnumerator, which was a kludge.
2016-02-21 12:53:47 +01:00
Max Kellermann
cadc67ea40
input: wrap InputStream in std::unique_ptr
2016-02-21 08:03:32 +01:00
Max Kellermann
054e9ecaae
tag/Id3Load: split tag_id3_read()
2016-02-21 07:14:04 +01:00
Max Kellermann
84fe3bfa87
tag/Id3Load: don't seek twice in tag_id3_read()
...
Copy the query buffer to the allocated buffer, and read only the
remaining data.
2016-02-19 19:43:05 +01:00
Max Kellermann
2ef8403bfa
tag/Id3Load: don't read again if we already have enough data
2016-02-19 19:40:23 +01:00
Max Kellermann
1d3b2baee7
tag/Id3Load: manage id3_tag* with std::unique_ptr
2016-02-19 19:16:40 +01:00
Max Kellermann
86de876b24
tag/TagId3: move tag_id3_load() to Id3Load.cxx
2016-02-19 19:06:06 +01:00
Max Kellermann
8a9f04f7fe
tag/Id3: catch exceptions
2016-02-19 18:23:54 +01:00
Max Kellermann
98bd4dfe04
fs/io/FileReader: add method Skip()
2016-02-19 18:18:25 +01:00
Max Kellermann
8e0e4d7c04
system/FileDescriptor: add method Skip()
2016-02-19 18:18:12 +01:00
Max Kellermann
a5e8269c72
tag/{Aiff,Riff}: allow fstat() to fail
...
Omit the file size check if we don't know the size.
2016-02-19 18:16:14 +01:00
Max Kellermann
0acc88cde5
Merge branch 'v0.19.x'
2016-02-19 18:16:04 +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
Christian Halaszovich
3392cbbd91
Emit a warning if the OutputThread fails to get realtime scheduling
...
This only applies to linux systems. Here, sched_setscheduler() is
called to get realtime scheduling. With this patch, the return value
of this function is now checked and a warning / error message is
generated if it fails.
2016-02-19 17:09:44 +01:00
Chris Spiegel
e7b211f2c0
Add TAK as a supported FFmpeg format.
2016-02-12 18:49:10 -08:00
Max Kellermann
6c5bc9b4a3
lib/expat: use C++ exceptions instead of class Error
2016-02-07 12:58:20 +01:00
Max Kellermann
cd2f65aafc
upnp/ContentDirectoryService: use AtScopeExit() for ixmlDocument_free()
...
For exception-safety.
2016-02-07 12:56:55 +01:00
Max Kellermann
3ee5093b03
lib/upnp: use C++ exceptions instead of class Error
2016-02-07 12:53:21 +01:00
Max Kellermann
6e2ad6860f
lib/upnp/ClientInit: use class ScopeLock
2016-02-07 12:53:21 +01:00
Max Kellermann
8610eb84c6
util/RuntimeError: add missing include
2016-02-07 12:53:21 +01:00
Max Kellermann
a2e008347c
Main: catch and log C++ exceptions
2016-02-07 12:42:09 +01:00
Max Kellermann
a1ef0159e3
playlist/PlaylistStream: catch and log C++ exceptions
2016-02-07 12:18:58 +01:00
Max Kellermann
1c5f76635a
playlist/SongEnumerator: wrap song in std::unique_ptr
2016-02-07 11:58:54 +01:00
Max Kellermann
e2a0fd7a28
playlist/cue/CueParser: Get() returns std::unique_ptr
2016-02-07 11:58:17 +01:00
Max Kellermann
5869a4ba2d
playlist/cue/CueParser: use std::unique_ptr
2016-02-07 08:31:51 +01:00
Max Kellermann
ac9a93261b
playlist/cue/CueParser: use C++11 initializers
2016-02-07 08:30:49 +01:00
Max Kellermann
4b79f0047d
db/DatabaseError: add exception class DatabaseError
2016-02-07 01:09:33 +01:00
Max Kellermann
6a789b660a
command/CommandError: move code to ToAck(DatabaseErrorCode)
2016-02-07 01:09:10 +01:00
Max Kellermann
0d8e44a079
db/DatabaseError: rename enum db_error and make strictly-typed
2016-02-07 01:01:10 +01:00
Max Kellermann
f097952b42
lib/upnp: use std::unique_ptr
2016-02-06 23:57:29 +01:00
Max Kellermann
224d511616
upnp/Discovery: use std::unique_ptr in WorkQueue
2016-02-06 22:26:14 +01:00
Max Kellermann
050c6cc4b0
upnp/Discovery: use AtScopeExit() for exception-safety
2016-02-06 22:06:43 +01:00
Max Kellermann
bc2d23ff0d
util/ScopeExit: new utility library
...
Similar to boost::scope_exit, but fewer include dependencies.
2016-02-06 22:03:37 +01:00
Max Kellermann
2939fadd6a
decoder/Control: use ScopeLock
2015-12-31 13:45:10 +01:00
Max Kellermann
ef260377c3
decoder/Internal: use ScopeLock
2015-12-31 13:44:19 +01:00
Max Kellermann
b9213df64b
decoder/API: use ScopeLock
2015-12-31 13:43:35 +01:00
Max Kellermann
aa7694047b
decoder/Thread: pass InputStream errors to DecoderControl::error
...
Give MPD clients access to the error condition.
2015-12-31 13:39:13 +01:00
Max Kellermann
e2bc63217a
decoder/Thread: decoder_input_stream_open() returns std::unique_ptr<InputStream>
...
Fixes memory leak after InputStream::Check() failure.
2015-12-31 13:39:13 +01:00
Max Kellermann
6c5b8bcf9d
decoder/Thread: log all errors
2015-12-31 13:38:35 +01:00
Max Kellermann
e425fe3f97
decoder/Thread: use std::unique_ptr<InputStream>
2015-12-31 13:12:28 +01:00
Max Kellermann
6507993972
decoder/Thread: move decoder_command_finished_locked() to DecoderControl
2015-12-31 13:06:31 +01:00
Max Kellermann
f081696f62
decoder/Thread: convert "int ret" to "bool success"
2015-12-31 13:02:55 +01:00
Max Kellermann
09157c3130
decoder/Thread: use ScopeLock in decoder_run_stream()
2015-12-31 13:01:49 +01:00
Max Kellermann
00626b1633
decoder/Thread: use std::unique_ptr<InputStream>
2015-12-31 13:01:03 +01:00
Max Kellermann
7e0cdbe502
decoder/Thread: use ScopeUnlock for exception-safety
2015-12-31 12:59:06 +01:00
Max Kellermann
ca08902d71
decoder/Thread: use ScopeLock in TryDecoderFile()
2015-12-31 12:58:58 +01:00
Max Kellermann
fad0e834d5
decoder/Thread: always unlock mutex before returning from TryDecoderFile()
...
Remove that surprising rule.
2015-12-31 12:57:35 +01:00
Max Kellermann
dc76eb6139
decoder/Thread: mutex not locked for decoder_run_{file,stream}()
2015-12-31 12:42:02 +01:00
Max Kellermann
55e113c7a7
decoder/Thread: document locking rules
2015-12-31 12:36:32 +01:00
Max Kellermann
b62f5e079e
decoder/Thread: use ScopeLock for exception-safety
2015-12-31 12:36:00 +01:00
Max Kellermann
ac1eaff6ec
thread/Mutex: add class ScopeUnlock()
2015-12-31 12:30:53 +01:00
Max Kellermann
45f6129ae7
player/Control: don't stop playback in Play()
...
Instead of stopping playback completely, only CANCEL the queued song
if necessary, and use the SEEK command to play the selected song.
SEEK will take care for current playback state.
2015-12-29 13:49:15 +01:00
Max Kellermann
f3503e0026
fs/DirectoryReader: use C++ exceptions instead of class Error
2015-12-29 12:56:26 +01:00
Max Kellermann
826a654c95
fs/DirectoryReader: use C++11 initializer
2015-12-29 12:56:26 +01:00
Max Kellermann
08754e6ce7
system/Error: add IsAccessDenied()
2015-12-29 12:56:26 +01:00
Max Kellermann
3843972b05
command/Error: workaround for gcc 4.x rethrow_exception(exception_ptr)
2015-12-29 12:39:28 +01:00
Max Kellermann
37862f0f20
PlaylistFile: convert more APIs from Error to std::exception
2015-12-28 14:20:37 +01:00
Max Kellermann
1f184f4aec
PlaylistFile: throw exception on spl_map_to_fs() failure
2015-12-28 14:20:37 +01:00
Max Kellermann
db5a691693
PlaylistFile: remove obsolete function TranslatePlaylistError()
2015-12-28 14:20:37 +01:00
Max Kellermann
48693250a4
command/Error: no std::exception_ptr forward declaration
...
This breaks on some standard library implementations.
2015-12-28 14:20:37 +01:00
Max Kellermann
570dcb6309
command/Error: support nested exceptions
2015-12-28 07:00:01 +01:00
Max Kellermann
19e43087a8
command/Error: move code to ToAck(std::exception_ptr)
2015-12-28 06:53:52 +01:00
Max Kellermann
fe0b6a1117
PlaylistFile: convert system_error::ENOENT to PlaylistResult::NO_SUCH_LIST
2015-12-28 06:44:01 +01:00
Max Kellermann
72851647ca
PlaylistError: fix NoSuchSong() code
2015-12-28 06:44:01 +01:00
Max Kellermann
1c90400081
command/Error: pass std::exception_ptr to PrintError()
...
Necessary to preserve type information. The try/catch sequence didn't
work previously.
2015-12-27 06:43:55 +01:00
Max Kellermann
672e18cac9
system/Error: fix duplicate strerror() call
...
Apparently, the std::system_error constructor appends strerror()
already.
2015-12-27 06:05:53 +01:00
Max Kellermann
e939d667d9
protocol/Ack: add exception class wrapping enum ack
2015-12-18 09:53:02 +01:00
Max Kellermann
8bb5a565cd
PlaylistError: add exception class wrapping enum PlaylistResult
2015-12-18 09:21:11 +01:00
Max Kellermann
7562c5751c
db/Configured: allocate ConfigBlock on the stack
2015-12-18 09:17:12 +01:00
Max Kellermann
e6e7d6dbd6
fs/io/Reader: use C++ exceptions instead of class Error
2015-12-18 01:08:16 +01:00
Max Kellermann
fe60c52c70
system/Error: add MakeErrno(), MakeLastError()
2015-12-18 01:08:16 +01:00
Max Kellermann
93f4590453
system/Error: add IsFileNotFound()
2015-12-18 00:54:23 +01:00
Max Kellermann
1098d271b8
util/Error: add bridge to std::exception
2015-12-18 00:24:43 +01:00
Max Kellermann
51168169e7
util/Tokenizer: use std::runtime_error on syntax error
2015-12-16 11:34:26 +01:00
Max Kellermann
d256a0e98f
config/ConfigFile: use std::exception on syntax error
2015-12-16 11:13:16 +01:00
Max Kellermann
6717325c3f
config/ConfigFile: use std::unique_ptr
2015-12-16 11:13:16 +01:00
Max Kellermann
c4a0571e7a
config/ConfigFile: fix typo in format string
2015-12-16 11:13:16 +01:00
Max Kellermann
e4a06da14e
fs/io/OutputStream: use C++ exceptions in Write()
2015-12-16 10:24:43 +01:00
Max Kellermann
36d6ead65c
fs/io/GzipOutputStream: use C++ exceptions in constructor
2015-12-16 10:14:56 +01:00
Max Kellermann
7eae3bc8c5
fs/io/FileOutputStream: use C++ exceptions in Commit()
2015-12-16 00:33:33 +01:00
Max Kellermann
24b2198668
fs/io/FileOutputStream: use C++ exceptions in constructor
2015-12-16 00:33:30 +01:00
Max Kellermann
d29be0f460
db/simple: use std::unique_ptr<GzipOutputStream>
2015-12-16 00:33:10 +01:00
Max Kellermann
8f93c36466
command/AllCommands: catch and report std::exception
2015-12-16 00:07:51 +01:00
Max Kellermann
3092e5a8a5
system/Error: helper library for constructing std::system_error
2015-12-16 00:07:51 +01:00
Max Kellermann
55f95b3ac9
Log: C++ exception support
2015-12-16 00:07:51 +01:00
Max Kellermann
c11345c4d9
db/DatabaseLock: add class ScopeDatabaseUnlock
2015-12-16 00:07:51 +01:00
Max Kellermann
e31f0b8b0c
db/simple: use class ScopeDatabaseLock
2015-12-16 00:07:51 +01:00
Max Kellermann
7dd3b72a8c
db/DatabaseLock: add ScopeDatabaseLock::unlock()
2015-12-16 00:07:51 +01:00
Max Kellermann
9bc0fada5c
release v0.19.12
...
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
iQIcBAABCAAGBQJWcH4fAAoJECNuiljG20USbAcQAKX0G+V10HI2Bmf7JJ3pWW96
GiOBpd66pEPioXdfpxOQNLglKS+rcproCWZnQf/VSoYN5d6pT6VLCQiMpdm3ZkNO
ZLWGhJ0Md1PGj+xjfGrMw95g+cqV+wMo1PETOsE/MtINqN/nMyQNI7lFnZ8xYEAP
DhJB1pXdchHvUVM3o+vpGSEOScn3XstL8+a/K5+Rvxptew4QDI/0ucyTLcLaaxkY
r/bH8wTDSMSpez4M5Me9MQ9OJ9NUPgudvs8Ppzji26lMcQRnZGdcffGTj08Lv+1b
gyx25t8sija6XVt6AEqn8KX+YAhe94c7ROq5PzdLeUszUf4YFIqaZ7O19PSYuuB6
APfr25A7NBQtJ88Wjw6slco+mAwbLZwQewZtFZCq6Y8J3oRBG6bpaPhFWUyygqTL
rIU735+o3FvqijKJUtKG0rAz+wfsPk6TMvIg4VMUaQXneS1LbzZe2Nz2FGxtonpd
Ua/tBQ/LnX8Utueuhy0kH06qPqq1/eSCMZIH/yphfR+B5k90h719RN/BR5xPv9Fb
vRdiSgPtfACAHvnadqcpVGjmmCQtXurC7gFceEc4Anign5kkSSGrDmo9OYhxwSkl
8A2GeOmxNrs2aFkNelnH3C6BTOEcewbXEmPQhTiBoX9LDmDK31rfSoVI0SUt7rbR
Sbt21m+7ThEqFfafZ8a/
=hDes
-----END PGP SIGNATURE-----
Merge tag 'v0.19.12'
release v0.19.12
2015-12-15 22:05:21 +01:00
Benno Fünfstück
cae2811762
fix mpd crash on invalid utf8 stream title
2015-12-15 21:49:53 +01:00
Max Kellermann
28f9a0a900
command/other: re-allow "lsinfo /"
...
This compatibility hack was accidently broken by commit f072cbbb
2015-11-13 21:04:02 +01:00
Max Kellermann
a6bb3cf60a
command/queue: use StringIsEqual() instead of memcmp()
...
memcmp() can overflow the buffer.
2015-11-13 21:02:33 +01:00