Commit Graph

372 Commits

Author SHA1 Message Date
Rosen Penev
71e551df42 replace locale.h with clocale
Switch to std:: functions. Changed the meson check. Works locally.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2020-03-31 18:05:23 -07:00
Max Kellermann
0da6344726 release v0.21.21
-----BEGIN PGP SIGNATURE-----
 
 iQJEBAABCgAuFiEEA5IzWngIOJSkMBxDI26KWMbbRRIFAl5zgCQQHG1heEBtdXNp
 Y3BkLm9yZwAKCRAjbopYxttFEnkCD/0RNcohFb2svCDYXuAz3BN5hBxUvepMJJId
 aNaT+jz8FpWTpIi4TaHqF4iODyDXR9YkVBv2aPqEjJad0tVEHHijyHkA25jd8moz
 lR46RRK4CEkBTTlmui9FmajelqoidMxRMQLR8HRTKCQPPZcgXhNOhdciJg1EovMT
 maZD81UyuZXPAq+v3IMJHy+H/LUA5yFcsjIdyJs7EEFZXHb9LUVRW/ZxUwFzl1Os
 TAiLQ0Ix4ebsy1MmE4n7f9T6dAuPO/+GkHXMKn6ruvAYUKPeKcjjdm5QW+Gyt9X1
 IArx0oaEqxPY5r7YruyGoPMj9pIwMVnHMLCTc8sbBNKS8ibtD/mlI+9Vj8C4gCoZ
 ZRjMFnPMSC6RmoTWbDw8U28j0vxMbQ/SWrLNIgW44QUHyFPfBgWNwqqKux6b/Mph
 u+SjVi/9ds8FKewLVi3dotdS8YmPF/b46Ov0ycfWLbyB7BvcP31o1zR1uLN6BqYj
 bzI4n4hKOxT0SsA74odJJDamA60J/DW4tAGxyscKaq8pDFYlBFo9dq+9+/aoDAMj
 sFLP32h/HqlO/ilZuuUVES4tg/shzF7VOhI9+GCvc/Ic1NXIdug4pUcXJ8ubXxzD
 ObnvF8RX8Vwf/ofwjcHIE7sqJAT5/QZhB1RTg/SkdlaUczjle0gVgCN1hAqlNSCP
 mJ8831lArg==
 =YxBZ
 -----END PGP SIGNATURE-----

Merge tag 'v0.21.21'

release v0.21.21
2020-03-19 15:26:27 +01:00
Max Kellermann
56c234b410 raise default "max_connections" value to 100
Documentation says the limit is 5, but it was really 10 (at least
since 2004).  But since MPD wants to promote using many small clients
idling around, and these clients consume only very few resources, it
seems reasonable to raise this limit's default value.
2020-03-19 13:30:46 +01:00
Rosen Penev
4b57b7f5a5
replace limits.h with climits
The former was deprecated with C++14. The standard says they are the same
with one exception:

The header<climits>defines all macros the same as the C standard library
header<limits.h>.

[Note:The types of the constants defined by macros in<climits>are not
required to match the types to which themacros refer.— end note]

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2020-03-12 16:14:04 -07:00
Max Kellermann
29d05cdb8e unix/SignalHandlers: pass Instance to ...Init() 2020-02-17 15:23:03 +01:00
Max Kellermann
72ec641f0d *: use auto 2020-02-01 14:02:43 +01:00
Max Kellermann
4df98466df output/multiple: add "client" field, replacing the "client" parameter
By eliminating GetAnyClient(), we can have instances with no outputs
at all.
2020-01-20 14:51:08 +01:00
Max Kellermann
879bafb837 Instance: move OnIdle() to Instance.cxx 2020-01-20 13:32:43 +01:00
Max Kellermann
6fcea2d484 Instance: move code to OnStateModified() 2020-01-20 13:28:00 +01:00
Max Kellermann
5d597a3646 Instance: manage StateFile with std::unique_ptr 2020-01-20 13:25:19 +01:00
Max Kellermann
5afec8256a Main: move code to Partition::BeginShutdown() 2020-01-20 09:22:28 +01:00
Max Kellermann
cd612c4eef AudioFormat: move to pcm/ 2020-01-18 20:24:59 +01:00
Max Kellermann
2817bf9e95 copyright year 2020 2020-01-18 19:23:49 +01:00
Max Kellermann
d663f81420 include cleanups (powered by iwyu) 2019-07-05 09:59:58 +02:00
Max Kellermann
e87f0ca771 pcm/Pcm*: drop more "Pcm" prefixes from source file names 2019-06-17 11:17:48 +02:00
Max Kellermann
a139279575 Copyright year 2019 2019-06-17 11:17:30 +02:00
Max Kellermann
5d74b5cee1 input/cache: first draft of the file cache 2019-05-31 17:49:52 +02:00
Max Kellermann
4eb101f046 config/Parser: add ParseSize()
Supports suffixes such as "kB" and "MB".
2019-05-29 22:44:05 +02:00
Max Kellermann
7d599c1afc Main: add Config constructor 2019-05-29 22:22:05 +02:00
Max Kellermann
7c565bce1d Main: move two more functions down 2019-05-29 22:20:02 +02:00
Max Kellermann
d17ff18ec0 Main: move main() to the bottom 2019-05-29 22:18:06 +02:00
Max Kellermann
efc6b1b77a Main: fold mpd_main_after_fork() into MainConfigured() 2019-05-29 22:16:32 +02:00
Max Kellermann
fdbec694c6 config/Param: add method With() 2019-05-29 21:50:04 +02:00
Max Kellermann
39046bed85 Instance: wrap ClientList in std::unique_ptr<> 2019-05-29 21:29:55 +02:00
Max Kellermann
71a5c8b819 Main: allocate Instance on the stack 2019-05-29 21:22:25 +02:00
Max Kellermann
620a39afb4 thread/Slack: use std::chrono::duration 2019-05-29 21:11:32 +02:00
Max Kellermann
14cee01ba1 Main: simplify Android startup 2019-05-29 15:08:39 +02:00
Max Kellermann
c782fdb698 Main: use AtScopeExit() to free Android objects 2019-05-29 15:08:38 +02:00
Max Kellermann
49ba76167e Main: add overload with ConfigData parameter 2019-05-29 15:08:26 +02:00
Max Kellermann
93ab957800 Main: convert int return types to void 2019-05-29 14:52:58 +02:00
Max Kellermann
f764925edc Instance: use std::unique_ptr<> to manage the NeighborGlue pointer 2019-04-25 13:09:31 +02:00
Max Kellermann
692c8025a2 Main: use AtScopeExit() to call NeighborGlue::Close() 2019-04-25 13:03:51 +02:00
Max Kellermann
77c9081f78 sticker/Database: wrap in class StickerDatabase 2019-04-25 12:05:18 +02:00
Max Kellermann
5a3828ed4a sticker/*: rename source files, drop "Sticker" prefix 2019-04-24 15:15:19 +02:00
Max Kellermann
1b62adc894 Instance: add noexcept 2019-04-24 14:56:08 +02:00
Max Kellermann
72ebd5ebdd java/Object: add Object.toString() wrapper 2019-04-24 14:08:51 +02:00
Max Kellermann
fe32db17d7 client/Internal: rename to Config.hxx 2019-04-03 21:31:32 +02:00
Max Kellermann
1213d979f8 client/*: rename source files, remove "Client" prefix 2019-04-03 20:59:00 +02:00
Max Kellermann
cc28a7b67f Main: create Database on stack, move to Instance after Open() succeeded
This fixes use-after-free bug in SimpleDatabase::Close(), accessing
the `root` object which was already freed by the `catch` block in
Open().

By having the Database on the stack first, we can avoid calling
Close() on the failed-to-open Database from Instance's destructor.

Closes #482
2019-02-20 20:50:28 +01:00
Max Kellermann
8b5c33cecd Instance: use std::unique_ptr<> to manage the Database pointer 2019-02-20 20:48:20 +01:00
Max Kellermann
6c28adbcd2 db/Plugin: use std::unique_ptr<> to manage Database pointers 2019-02-20 20:43:31 +01:00
Max Kellermann
f70eb63879 Instance: eliminate FinishShutdownUpdate(), move code to destructor 2019-02-15 18:20:11 +01:00
Max Kellermann
99c23cf139 Instance: eliminate ShutdownDatabase(), move code to destructor
Destruct automatically, even if leaving the scope due to exception
being thrown.
2019-02-15 18:04:23 +01:00
Max Kellermann
e9c45a9140 playlist/Registry: add RAII class 2019-02-05 23:03:29 +01:00
Max Kellermann
a065c6e6b9 Main: use AtScopeExit() to call DeinitFS() 2019-02-05 23:02:50 +01:00
Max Kellermann
feb5ff9bd2 Mapper: remove empty function mapper_finish() 2019-02-05 23:01:09 +01:00
Max Kellermann
98c47d9d36 Instance: remove FinishShutdownPartitions()
The list of partitions is cleared automatically.
2019-02-05 22:53:02 +01:00
Max Kellermann
261a816b21 command/AllCommands: remove empty function command_finish() 2019-02-05 22:15:41 +01:00
Max Kellermann
7a23c123c8 decoder/List: add RAII class 2019-02-05 22:12:22 +01:00
Max Kellermann
9e73ea77b4 input/Init: add RAII class 2019-02-05 22:07:49 +01:00