Commit Graph

10836 Commits

Author SHA1 Message Date
Max Kellermann
b14fc907f9 lib/expat/Parser: forward Parse() arguments 2018-01-21 14:34:53 +01:00
Max Kellermann
542bbb0889 input/qobuz: parse and report message from error responses 2018-01-21 12:52:54 +01:00
Max Kellermann
714e69e708 input/qobuz: create JSON parser on demand 2018-01-21 12:49:10 +01:00
Max Kellermann
cb87ed29d8 input/tidal: invoke login handlers on second request
Fixes a freeze bug.
2018-01-21 12:41:19 +01:00
Max Kellermann
570c6765b0 input/tidal: parse and report userMessage from error responses 2018-01-21 12:30:46 +01:00
Max Kellermann
12a2285ba5 input/tidal: create JSON parser on demand 2018-01-21 12:29:52 +01:00
Max Kellermann
1c023eac70 db/update/Walk: add "noexcept" 2018-01-21 11:53:59 +01:00
Max Kellermann
1e3f0650df SongUpdate: add "noexcept" 2018-01-21 11:53:42 +01:00
Max Kellermann
1e9da09f62 TagFile: add "noexcept" 2018-01-21 11:53:42 +01:00
Max Kellermann
5caf351c44 TagArchive: add "noexcept" 2018-01-21 11:53:42 +01:00
Max Kellermann
7d789a984a decoder/Plugin: add "noexcept" 2018-01-21 11:47:17 +01:00
Max Kellermann
d921114832 db/Helpers: add "noexcept" 2018-01-21 11:37:13 +01:00
Max Kellermann
39a1f03d5c db/PlaylistVector: add "noexcept" 2018-01-21 11:36:16 +01:00
Max Kellermann
c6a4a4edf1 playlist/Print: add "noexcept" 2018-01-21 11:35:31 +01:00
Max Kellermann
45748a2bb0 playlist/Song: add "noexcept" 2018-01-21 11:35:28 +01:00
Max Kellermann
9b13d862c1 playlist/Registry: add "noexcept" 2018-01-21 11:35:27 +01:00
Max Kellermann
590edc648a playlist/Plugin: add "noexcept" 2018-01-21 11:35:25 +01:00
Max Kellermann
3326c87a88 db/Count: add "noexcept" 2018-01-21 11:33:53 +01:00
Max Kellermann
0ec1863fcb db/Print: add "noexcept" 2018-01-21 11:32:22 +01:00
Max Kellermann
2b67a14155 SongPrint: add "noexcept" 2018-01-21 11:32:10 +01:00
Max Kellermann
eac8caa4de TagPrint: add "noexcept" 2018-01-21 11:30:47 +01:00
Max Kellermann
61eb2aa328 storage/Interface: wrap StorageDirectoryReader in std::unique_ptr 2018-01-21 11:04:30 +01:00
Max Kellermann
a9847ebf54 playlist/Queue: use "auto" 2018-01-20 20:14:19 +01:00
Max Kellermann
4ca1089f60 input/TextInputStream: ReadLine() throws exception on error 2018-01-20 20:13:08 +01:00
Max Kellermann
926d4150c5 playlist/SongEnumerator: allow NextSong() to throw exceptions 2018-01-20 20:11:15 +01:00
Max Kellermann
6f267adc14 playlist/SongEnumerator: add "noexcept" 2018-01-20 20:10:46 +01:00
Max Kellermann
0095e2d7d8 playlist/Plugin: use std::unique_ptr<SongEnumerator> 2018-01-20 19:59:42 +01:00
Max Kellermann
147f64e1fc playlist/Plugin: remove useless wrapper functions 2018-01-20 19:58:11 +01:00
Max Kellermann
b8e5932506 tag/{Tag,Builder}: use std::lock_guard 2018-01-20 19:53:38 +01:00
Max Kellermann
1ea04cd8cc tag/Pool: add "noexcept" 2018-01-20 19:53:38 +01:00
Max Kellermann
b334643b68 tag/Pool: use C++11 initializers 2018-01-20 19:53:38 +01:00
Max Kellermann
6e6a0275b5 tag/Pool: use uint8_t instead of unsigned char 2018-01-20 19:53:38 +01:00
Max Kellermann
f5590806e0 tag/Handler: add "noexcept" 2018-01-20 19:53:38 +01:00
Max Kellermann
f686e838fe tag/Builder: add "noexcept" 2018-01-20 19:53:38 +01:00
Max Kellermann
ea8642dec9 tag/Builder: use C++11 initializers 2018-01-20 19:53:38 +01:00
Max Kellermann
eef5b58211 tag/Tag: add "noexcept" 2018-01-20 19:39:46 +01:00
Max Kellermann
1de68b72b9 tag/Tag: use C++11 initializers 2018-01-20 19:39:06 +01:00
Max Kellermann
720df085e5 input/TextInputStream: add "noexcept" 2018-01-20 19:35:09 +01:00
Max Kellermann
f90f17227b input/Domain: remove obsolete variable 2018-01-20 19:19:29 +01:00
Max Kellermann
36f7eaadef input/LocalOpen: make assert() more strict 2018-01-20 19:15:51 +01:00
Max Kellermann
1eb9300658 input/LocalOpen: include cleanup 2018-01-20 19:14:42 +01:00
Max Kellermann
27e4656515 input/{file,archive}: remove the dummy InputPlugin instances
These have no use, exception for creating an artificial dependency
from input_plugins[] to all archive plugins.
2018-01-20 19:07:34 +01:00
Max Kellermann
e0a09dbd69 input/thread: add "noexcept" 2018-01-20 18:54:29 +01:00
Max Kellermann
30832ab33a input/InputStream: add "noexcept" to constructor 2018-01-20 18:53:37 +01:00
Max Kellermann
d20b545a94 input/InputStream: remove methods Lock() and Unlock()
These methods are not exception-safe; std::lock_guard should better be
used.
2018-01-20 18:51:23 +01:00
Max Kellermann
20d01be1ad input/mms: use class ScopeUnlock 2018-01-20 18:51:00 +01:00
Max Kellermann
d6b62d7512 input/tidal: delete request objects upon completion 2018-01-20 00:34:44 +01:00
Max Kellermann
ab9d9541a8 input/tidal: pass std::string by value
Don't keep any references to the owner, as the handler method may
delete the owner.
2018-01-20 00:33:01 +01:00
Max Kellermann
c3b8568560 lib/curl/Handler: add API documentation 2018-01-20 00:28:54 +01:00
Max Kellermann
8bd95a4eb1 db/update/Container: include cleanup 2018-01-20 00:25:57 +01:00
Max Kellermann
2dac3ef58e client: eliminate client_printf() 2018-01-20 00:24:18 +01:00
Max Kellermann
86c7ab29f4 client/Idle: pass Response instead of Client to WriteIdleResponse() 2018-01-20 00:22:47 +01:00
Max Kellermann
db89e5ec28 client/Idle: move code to WriteIdleResponse() 2018-01-20 00:22:30 +01:00
Max Kellermann
d096f75fb8 client/Idle: apply idle_subscriptions mask once 2018-01-20 00:22:09 +01:00
Max Kellermann
854424a758 client/Idle: use std::exchange() 2018-01-20 00:21:26 +01:00
Max Kellermann
fe5d0ce827 Merge branch 'v0.20.x' 2018-01-20 00:04:35 +01:00
Max Kellermann
8376578921 db/simple/Mount: drop mount point prefix from LOCATE_TAG_BASE_TYPE
Fixes search within mount points, resulting in error "No such
directory".

Closes #190
2018-01-19 23:52:57 +01:00
Max Kellermann
ed2354cd9d SongFilter: allow copying items 2018-01-19 23:52:03 +01:00
Max Kellermann
386688b87a SongFilter: use std::string instead of AllocatedString 2018-01-19 23:51:42 +01:00
Max Kellermann
38d56dddf1 lib/icu/Compare: allow copying 2018-01-19 23:49:50 +01:00
Max Kellermann
3ca80a7336 util/RefCount, db/simple/Mount: remove obsolete libc++ workarounds
No longer a problem with NDK r16.
2018-01-19 23:19:46 +01:00
Max Kellermann
2fed3b5e5b input/Tidal*Request: add Start() method
The caller should be able to safely store the instance pointer before
his callback is invoked.
2018-01-19 16:03:05 +01:00
Max Kellermann
1ecad094bd input/tidal: add API documentation 2018-01-19 16:03:03 +01:00
Stefan Roellin
187cc573a7 db/upnp/Directory: fix parsing of durations with fractions of seconds
The duration of a song can have fractions of seconds
(quote from http://www.upnp.org/schemas/av/didl-lite-v2.xsd):

    The format of the duration string is:
    H+:MM:SS[.F+], or H+:MM:SS[.F0/F1]
    Where:
    +H              one or more digits to indicate elapsed hours,
    MM              exactly 2 digits to indicate minutes (00 to 59),
    SS              exactly 2 digits to indicate seconds (00 to 59),
    F+              any number of digits (including no digits) to indicate fractions of seconds,
    F0/F1   a fraction, with F0 and F1 at least one digit long,
                    and F0 < F1.
    The string may be preceded by an optional + or - sign, and the
    decimal point itself may be omitted if there are no fractional  seconds digits.

Until now, a duration with fractions of seconds could not be parsed and
resulted in an unknown duration. Only durations in the format "H+:MM:SS"
were feasible. This commit enables to read durations in the first format,
i.e. "H+:MM:SS[.F+]"
2018-01-19 15:53:18 +01:00
Max Kellermann
0ead72a404 lib/upnp/ContentDirectoryService: work around GCC 5 bug
Closes #193
2018-01-18 21:55:58 +01:00
Max Kellermann
bbc5212436 fs/AllocatedPath: make the nullptr_t constructor public 2018-01-17 12:17:41 +01:00
Max Kellermann
c4f7740b80 fs/Path: replace method Null() with nullptr_t constructor 2018-01-17 12:16:21 +01:00
Max Kellermann
3e2e0d062b util/OptionParser: support option values 2018-01-17 11:14:57 +01:00
Max Kellermann
c45fe3517c util/OptionParser: add struct Result
Prepare for option values.
2018-01-17 11:08:05 +01:00
Max Kellermann
d588da69e5 CommandLine: convert pointer to reference 2018-01-17 11:08:03 +01:00
Max Kellermann
ec54a5c72c CommandLine: use C++11 initializers 2018-01-17 11:08:02 +01:00
Max Kellermann
735a371249 util/OptionParser: pass array of OptionDefs to constructor 2018-01-17 10:24:06 +01:00
Max Kellermann
5ab086e337 util/OptionParser: loop in ParseNext() until a new option is found 2018-01-16 11:25:18 +01:00
Max Kellermann
68f660dbcc util/OptionParser: collect remaining arguments
Allow the caller to use a simple "for" loop without checking
arguments.
2018-01-16 11:08:23 +01:00
Max Kellermann
0066f7a818 util/{Const,Writable}Buffer: add constructor with two pointers 2018-01-16 11:06:33 +01:00
Max Kellermann
65059f2add util/{Const,Writable}Buffer: eliminate static method Null(), use nullptr cast instead 2018-01-16 11:04:51 +01:00
Max Kellermann
23dff4f209 util/OptionParser: use ConstBuffer<const char*> to store argv/argc 2018-01-16 10:22:06 +01:00
Max Kellermann
4a304bf34e util/OptionParser: make string pointers "const" 2018-01-16 10:20:53 +01:00
Max Kellermann
36a6405e8b util/OptionParser: add "constexpr" 2018-01-16 10:20:52 +01:00
Max Kellermann
42c1fe963b util/OptionParser: add "noexcept" 2018-01-16 10:13:39 +01:00
Max Kellermann
465b154fc0 util/OptionParser: use C++11 initializers 2018-01-16 10:12:48 +01:00
Max Kellermann
a0c4102b5a util/OptionDef: add "constexpr" 2018-01-16 10:11:35 +01:00
Max Kellermann
9420066895 input/qobuz: new input plugin to receive Qobuz streams 2018-01-15 21:50:20 +01:00
Max Kellermann
74eac1d449 lib/curl/Request: add constructor without "url" parameter
Allows constructing the request first and set the URL later.  This is
needed because curl_easy_escape() is needed to construct the URL,
which however needs the CURL "easy" handle created by the Request class.
2018-01-15 10:36:48 +01:00
Max Kellermann
96676f8f3b Merge branch 'v0.20.x' 2018-01-15 09:06:31 +01:00
Max Kellermann
93b51d56aa input/tidal: new input plugin to receive Tidal streams 2018-01-12 14:33:22 +01:00
Max Kellermann
86c50574d2 lib/yajl/Callbacks: add wrappers for start_array and end_array 2018-01-12 14:33:22 +01:00
Max Kellermann
efb528f979 player/Thread: wake up the decoder when the pipe has run empty
This is another instance of the kludge we already have a few lines
above that.  It works around a deadlock/race condition revealed by
commit 98a7c62d7a
2018-01-12 14:33:22 +01:00
Max Kellermann
edcd0b9913 lib/curl/Request: add methods StartIndirect(), StopIndirect() 2018-01-11 20:51:23 +01:00
Max Kellermann
55d1473918 lib/yajl/Callbacks: OO wrapper for yajl_callbacks 2018-01-11 20:25:17 +01:00
Max Kellermann
0211c7f7f3 lib/yajl/ParseInputStream: use InputStream::LockRead() to reduce lock duration 2018-01-11 20:11:04 +01:00
Max Kellermann
5913994169 lib/yajl/ParseInputStream: eliminate variable "done" 2018-01-11 20:09:52 +01:00
Max Kellermann
26b1573cbe playlist/SoundCloud: move code to Yajl::Parse(InputStream&) 2018-01-11 20:08:02 +01:00
Max Kellermann
7fe07324d7 playlist/SoundCloud: soundcloud_parse_json() throws exception 2018-01-11 20:08:01 +01:00
Max Kellermann
8e29430f21 lib/yajl/Handle: libyajl C++ bindings 2018-01-11 19:25:46 +01:00
Max Kellermann
cb86023bd7 lib/curl/Form: new library 2018-01-11 17:27:25 +01:00
Max Kellermann
bd2cb40424 lib/curl/Easy: add curl_easy_escape() wrapper 2018-01-11 17:27:25 +01:00
Max Kellermann
e9a3ff0e70 input/failing: new class 2018-01-11 16:18:15 +01:00
Max Kellermann
5148e229e0 input/proxy: allow input==nullptr
Allow implementations to install the "real" input later.
2018-01-11 15:57:57 +01:00
Max Kellermann
1ad21c27c9 input/curl: add public function to construct an instance 2018-01-11 15:53:46 +01:00