Commit Graph

906 Commits

Author SHA1 Message Date
Rosen Penev 50d35c9677 upnp: use UpnpInit2 always
libupnp 1.14 removes the non 2 function. Fixes compilation there.

Signed-off-by: Rosen Penev <rosenp@gmail.com>

Closes https://github.com/MusicPlayerDaemon/MPD/issues/1499
2022-04-26 17:57:48 +02:00
Andreas Ziegler ee39af3419 fix typo in comment 2022-04-24 04:14:17 +00:00
aeolio 3882a5a263 src/lib/icu: fix iconv() detection when libiconv is installed 2022-04-20 16:10:39 +02:00
Max Kellermann a360475c7b Merge branch 'v0.23.x' 2022-03-26 06:49:51 +01:00
Max Kellermann a757eebfbb decoder/OggSyncState: allow skipping up to 64 kB after seek
This is more of what we did in commit 70bd35abe2 because it turns
out there are Ogg-Opus files with pages larger than 40 kB.

Closes https://github.com/MusicPlayerDaemon/MPD/issues/1487
2022-03-16 16:54:50 +01:00
Max Kellermann 407fa2720a Merge tag 'v0.23.6'
release v0.23.6
2022-03-14 18:58:47 +01:00
Max Kellermann 71cd6e6248 lib/xiph/meson.build: define FLAC__NO_DLL for static libFLAC build (Windows)
In libFLAC 0.3.4 (commit c9530118a4), the "dllimport" check has been
changed from "_MSC_VER" to "_WIN32", and now the MPD build is affected
by it.

Defining FLAC__NO_DLL disables the use of "dllimport", which allows
linking properly to the static libFLAC build.
2022-03-14 15:08:59 +01:00
Max Kellermann 603bbe0afd python/build/libs.py: update libnfs to 5.0.1 2022-03-14 14:52:24 +01:00
Max Kellermann 8e99448819 lib/curl/Headers: make the comparison type "transparent" 2022-02-14 18:19:28 +01:00
Max Kellermann 1e548fb6e3 lib/curl/Headers: central type definition for the header map 2022-02-14 18:19:05 +01:00
Max Kellermann 946cf25732 Merge branch 'v0.23.x' 2022-01-26 14:44:37 +01:00
Max Kellermann aea4d3c4b0 lib/zlib/GunzipReader: use std::size_t 2022-01-10 16:59:13 +01:00
aeolio 3856224df9 lib/alsa/Error: add missing #include 2021-12-15 11:14:38 +01:00
aeolio 6d4bedfc56 lib/alsa/Error: fix typo 2021-12-15 11:14:34 +01:00
Max Kellermann dda0dfc140 lib/curl/Request: move code from SetupEasy() to Setup.cxx 2021-12-08 20:03:30 +01:00
Max Kellermann e0f56b9e2d lib/curl/Request: move code to class CurlResponseHandlerAdapter 2021-12-08 19:51:54 +01:00
Max Kellermann 50a617764a lib/curl/Handler: fix typo 2021-12-08 19:41:39 +01:00
Max Kellermann cdcef49eef lib/curl/Request: add constructor with CurlEasy parameter 2021-12-07 12:01:09 +01:00
Max Kellermann 9e18aafccc lib/curl/Request: use std::size_t 2021-12-07 12:00:12 +01:00
Max Kellermann f7346c1d78 lib/curl/Request: move code to SetupEasy() 2021-12-07 11:57:42 +01:00
Max Kellermann b709401814 lib/curl/Request: add API docs 2021-12-07 11:56:45 +01:00
Max Kellermann b6ba17a865 Merge branch 'v0.23.x' 2021-12-06 21:32:48 +01:00
Max Kellermann 2240327286 ReplayGainInfo: move to tag/ 2021-12-06 09:28:36 +01:00
Rosen Penev 4e276256c0 more braced init list conversion
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-12-06 09:16:04 +01:00
Max Kellermann a5fa43b526 fs/io: move to io/ 2021-12-03 14:35:41 +01:00
Max Kellermann 20bf1d68e6 MixRampInfo: move to tag/ 2021-12-01 17:09:02 +01:00
Max Kellermann 9bc4c168fd tag/MixRamp: rename to MixRampParser.cxx 2021-12-01 17:07:53 +01:00
Max Kellermann 933a1a41e6 lib/upnp/Discovery: use InjectEvent instead of DeferEvent
Fixes regression by commit 774b4313f2
2021-11-30 18:03:27 +01:00
Max Kellermann 868f1a4431 net/UniqueSocketDescriptor, ...: include <utility> instead of <algorithm>
Since C++11, std::swap() lives in <utility>.
2021-11-26 16:25:29 +01:00
Rosen Penev f22cf02ed8 fix wrong namespace name
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-11-26 08:08:45 +01:00
Rosen Penev 29ae84e199 manual braced init
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-11-22 23:30:04 -08:00
Rosen Penev 250011f016 return by braced init list
shorter

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-11-22 23:28:08 -08:00
Max Kellermann 77df5a8f24 lib/pcre: migrate to PCRE2
Closes https://github.com/MusicPlayerDaemon/MPD/issues/1352
2021-11-22 19:32:45 +01:00
Max Kellermann f74996c02f Merge remote-tracking branches 'neheb/1', 'neheb/2', 'neheb/3', 'neheb/4' and 'neheb/5' 2021-11-20 07:55:24 +01:00
Max Kellermann eea2d35d3a util/AllocatedString, ...: add missing include for std::exchange()
Fixes building with GCC 12.
2021-11-19 16:06:20 +01:00
Rosen Penev 5deca66fdc add various nodiscard
Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-11-11 17:17:26 -08:00
Rosen Penev 4e0e4c00bf treewide: replace lock_guard with scoped_lock
SonarLint reports the latter to be better:

std::scoped_lock basically provides the same feature as std::lock_guard,
but is more generic: It can lock several mutexes at the same time, with a
deadlock prevention mechanism (see {rule:cpp:S5524}). The equivalent code
to perform simultaneous locking with std::lock_guard is significantly more
complex. Therefore, it is simpler to use std::scoped_lock all the time,
even when locking only one mutex (there will be no performance impact).

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-11-11 17:13:03 -08:00
Rosen Penev 31aa6d0c4f use auto with make_unique
C arrays can be used with make_unique in C++17.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2021-11-11 01:33:03 -08:00
Max Kellermann 5f4ec7de5b decoder/ffmpeg, lib/ffmpeg: make AVCodec pointers "const"
For libavcodec 59 support.

Closes https://github.com/MusicPlayerDaemon/MPD/issues/1333
2021-11-09 21:09:14 +01:00
Max Audron 4ed60a5711 upnp: expose interface configuration on UpnpInit2()
Adds the Interface Name as an argument to the *Init functions to make it
possible to select which interface is used by upnp to detect servers.

Currently "nullptr" is passed in to let the upnp library select an
interface, as before.
2021-11-08 22:53:01 +01:00
Max Kellermann 356d13e9dd lib/alsa/HwSetup: add missing include 2021-11-04 17:55:15 +01:00
Max Kellermann 5d0941476a lib/alsa/Error: a std::system_error category for libasound errors 2021-11-04 14:59:00 +01:00
Max Kellermann 5ff0bbd0f8 lib/fmt/AudioFormatFormatter: add formatter for SampleFormat 2021-11-04 14:55:01 +01:00
Max Kellermann a9344fafe9 lib/alsa/AllowedFormat: use StringView::RemoveSuffix() 2021-10-23 11:43:31 +02:00
Max Kellermann b8890726f2 lib/alsa/AllowedFormat: use std::string_view 2021-10-23 11:42:30 +02:00
Max Kellermann f447b7615e output/pipewire: check pw_stream_connect() errors 2021-10-20 11:24:51 +02:00
Max Kellermann 5fab107fd3 lib/nfs/FileReader: use the thread-safe InjectEvent
.. instead of DeferEvent, which is not thread-safe.  This caused
various playback problems, which was initially caused by the
DeferEvent/InjectEvent split in commit 774b4313f2

Closes https://github.com/MusicPlayerDaemon/MPD/issues/1298
2021-10-20 09:38:09 +02:00
Max Kellermann 771c46032f meson.build: add missing libfmt dependencies
Fixes https://github.com/MusicPlayerDaemon/MPD/discussions/1281

The problem occurred when there was libfmt-dev installed, but it was
too old (e.g. on Debian Buster), and Meson used the wrap fallback.
Those internal MPD libraries where the libfmt dependency was not
declared were still using the old system libfmt headers, which are not
ABI-compatible with MPD's own libfmt build.
2021-10-15 14:26:59 +02:00
Max Kellermann 72f6e018e7 Log: remove the obsolete printf-style functions 2021-10-13 17:41:19 +02:00
Max Kellermann 2fbbd540bb more [[gnu::...]] attributes 2021-10-13 17:38:01 +02:00