Max Kellermann
f2c926f3b6
zeroconf/glue: add fallback value for HOST_NAME_MAX
...
`HOST_NAME_MAX` is not a portable macro; it is undefined on some
systems.
Closes #402
2018-11-04 11:12:03 +01:00
Max Kellermann
528f5b9cb9
song/Filter: allow escaping quotes in filter expressions
...
Closes #397
2018-11-02 19:15:08 +01:00
Max Kellermann
5a5229b499
net/IPv[46]Address: make the initializers more portable
...
Thanks to C++14, we can declare and fill variables inside `constexpr`
functions. This means me can stop make assumptions on the `struct`
layouts without losing `constexpr`.
Closes #393
2018-11-02 17:47:43 +01:00
Max Kellermann
bba22c9c8c
system/FileDescriptor: check __linux__
instead of __linux
...
`__linux` is the deprecated non-standard macros which appears to be
not present at all on PowerPC.
Closes #398
2018-11-02 16:50:38 +01:00
Max Kellermann
2a926063b2
src/lib/ffmpeg/meson.build: copy dependencies into ffmpeg_dep
...
Apparently, Meson propagates the linker flags but not the compiler
flags from a `static_library`'s dependencies list.
Closes #392
2018-11-01 19:14:00 +01:00
Max Kellermann
657ef48518
zeroconf/glue: use strstr() and std::string::replace() instead of std::regex_replace()
...
std::regex_replace() is heavily bloated and overkill for this feature.
2018-10-31 19:26:37 +01:00
Max Kellermann
8a492c8f39
Merge branch 'bug516974' of git://github.com/fschlich/MPD
2018-10-31 19:20:41 +01:00
Max Kellermann
901a48c9a4
command/sticker: return ACK_ERROR_NO_EXIST for "no such sticker"
...
Closes #389
2018-10-31 19:19:07 +01:00
Max Kellermann
f5c9071494
*: copyright year 2018
2018-10-31 17:54:59 +01:00
Florian Schlichting
d1f85240a2
include hostname in zeroconf_name ( fixes #387 )
...
expand %h to the system hostname and default to a zeroconf string that
contains %h
2018-10-31 17:54:45 +01:00
Max Kellermann
2148d4bb31
fs/io/FileOutputStream: fix -Wcomment
2018-10-31 17:18:44 +01:00
Max Kellermann
e79d06d595
fs/io/FileOutputStream: don't use O_TMPFILE on Android
...
Fixes writing to Context.getCacheDir().
2018-10-31 17:12:21 +01:00
Max Kellermann
c60cf944f5
fs/io/FileOutputStream: add macro HAVE_O_TMPFILE
2018-10-31 17:10:52 +01:00
Max Kellermann
06ca08ce55
output/roar: remove
...
Bugs in libroar which broke the MPD build have been annoying me for
quite some time, and the newest bug has now hit my main build machine:
https://github.com/MusicPlayerDaemon/MPD/issues/377
Problem is the usage of the typedef `_IO_off64_t` in libroar's
`vio_stdio.h`:
int roar_vio_to_stdio_lseek (void *__cookie, _IO_off64_t *__pos, int __w);
This `_IO_off64_t` is an internal implementation detail of glibc and
was removed in version 2.28. Nobody must ever use it. Why the ****
did the RoarAudio developers use it? Not using internal typedefs
isn't exactly rocket science.
This annoys me enough to finally remove the plugin. Anyway, I've
never heard of anybody using RoarAudio, so my best guess is that
nobody will notice.
2018-10-31 15:03:28 +01:00
Max Kellermann
9fc00a817b
Listen: use fs/XDG.hxx
...
This keeps one central place for the XDG switch. Specifically, this
disables the XDG listener on Apple, where XDG is not supported.
2018-10-31 14:30:34 +01:00
Max Kellermann
f47696f5f8
fs/StandardDirectory: move USE_XDG to XDG.hxx
2018-10-31 13:39:20 +01:00
Florian Schlichting
db21d7de0b
fix compilation errors on Debian GNU/Hurd
...
Apparently on hurd-i386 __GLIBC__ is defined, but the pthread
implementation is special and cannot be used with constexpr. Hence
exclude __gnu_hurd__.
2018-10-31 12:24:34 +01:00
Max Kellermann
56112a237c
Listen: listen on $XDG_RUNTIME_DIR/mpd/socket by default
2018-10-30 22:14:54 +01:00
Max Kellermann
64da9399ca
event/ServerSocket: allow mixing AddFD() with other Add*() methods
2018-10-30 22:14:53 +01:00
Max Kellermann
0ec31b4aa4
Listen: eliminate listen_add_config_param()
2018-10-30 21:14:39 +01:00
Max Kellermann
a943f4063c
event/ServerSocket: add AddFD() overload with AllocatedSocketAddress&&
2018-10-30 20:44:56 +01:00
Max Kellermann
ce9f09c69a
event/ServerSocket: make AddAddress() a template
2018-10-30 20:43:52 +01:00
Max Kellermann
3ddc7a5353
event/ServerSocket: include cleanup
2018-10-30 20:19:07 +01:00
Max Kellermann
e575392b94
event/ServerSocket: use class IPv6Address
2018-10-30 20:19:04 +01:00
Max Kellermann
c6f61a699c
event/ServerSocket: make OneServerSocket an inner class
2018-10-30 20:16:26 +01:00
Max Kellermann
0307b49f43
event/ServerSocket: make OnAccept() noexcept
2018-10-30 20:13:07 +01:00
Max Kellermann
413ab80295
event/ServerSocket: use C++11 initializer
2018-10-30 20:11:58 +01:00
Max Kellermann
daffefdb10
event/ServerSocket: pass UniqueSocketDescriptor to AddFD()
2018-10-30 20:05:57 +01:00
Max Kellermann
5fb21fbdb1
event/ServerSocket: add noexcept
2018-10-30 19:57:39 +01:00
Max Kellermann
f5857c4689
net/SocketUtil: update API documentation
2018-10-30 19:56:10 +01:00
Max Kellermann
c97469283c
pcm: build dsd2pcm only if -Dtest=true
2018-10-30 13:31:43 +01:00
Max Kellermann
9b1f44e758
LogInit: work around two Android compiler warnings
2018-10-30 13:23:10 +01:00
Max Kellermann
804ccddf7e
pcm/Clamp: convert to constexpr
2018-10-30 00:08:25 +01:00
Max Kellermann
bb5918932b
pcm/PcmUtils: rename to Clamp.hxx
2018-10-30 00:05:58 +01:00
Max Kellermann
aa77bc323f
pcm/FloatConvert: make IntegerToFloatSampleConvert::Convert() constexpr
2018-10-29 23:52:25 +01:00
Max Kellermann
9b6a2589e5
Merge branch 'v0.20.x'
2018-10-29 23:06:32 +01:00
Max Kellermann
cc5fab28af
pcm/FloatConvert: fix compile-time integer overflow for S32
...
The compile-time calculation for `factor` overflows because `1<<31`
cannot be represented by `int`. By casting to `uintmax_t` first, we
can avoid this overflow.
Closes #380
2018-10-29 22:50:54 +01:00
Max Kellermann
a3f7127e72
pcm/FloatConvert: use FloatToIntegerSampleConvert::factor for IntegerToFloatSampleConvert::factor
2018-10-29 22:50:06 +01:00
Max Kellermann
b0a6a569df
pcm/FloatConvert: add static_assert
on the factor
...
This assertion currently fails for S32 due to integer overflow (#380 ).
2018-10-29 22:38:32 +01:00
Max Kellermann
92523f8cf2
input/CdioParanoia: parse_cdio_uri() returns CdioUri
...
The `bool` return value isn't used anymore, so we can just return the
parsed object instead of passing it as an output parameter.
2018-10-29 14:34:33 +01:00
Max Kellermann
e33c08357a
input/CdioParanoia: rename struct cdio_uri to CdioUri
2018-10-29 14:34:30 +01:00
Max Kellermann
2dc5648e57
input/CdioParanoia: use StringAfterPrefixIgnoreCase()
2018-10-29 14:34:30 +01:00
Max Kellermann
d0349880da
util/StringCompare: add StringAfterPrefixIgnoreCase()
2018-10-29 14:34:29 +01:00
Max Kellermann
7aa1dceef6
player/Control: move IDLE_PLAYER to Player::SeekDecoder()
...
This emits the event even if PlayerControl::Play() is used to replay
the current song, which emits the missing "player" idle event.
Closes #381
2018-10-29 12:01:48 +01:00
Max Kellermann
f76544be4c
db/update: catch all exceptions
2018-10-29 11:05:50 +01:00
Max Kellermann
1e6c445320
configure.ac: add -funwind-tables
to work around clang bug
...
Replaces the workaround from commit
751fff07fb
which fixed only one of many
crash locations.
See:
https://github.com/MusicPlayerDaemon/MPD/issues/373
https://github.com/android-ndk/ndk/issues/831
https://bugs.llvm.org/show_bug.cgi?id=32611
2018-10-29 11:05:35 +01:00
Max Kellermann
eeae9a04d3
input/Registry: add missing include
2018-10-25 09:21:13 +02:00
Max Kellermann
8bb35e7bb6
decoder/Thread: reimplement HasRemoteTagScanner() using the InputPlugin list
2018-10-25 09:09:21 +02:00
Max Kellermann
3e78c9ab48
input/Plugin: add attribute prefixes
2018-10-24 20:25:32 +02:00
Max Kellermann
9ec86acb9c
decoder/Thread: enable output tags for Tidal and Qobuz
...
Fixes formatted paths in the `recorder` output, closing #345 .
2018-10-24 16:38:26 +02:00