Commit Graph

15440 Commits

Author SHA1 Message Date
Max Kellermann 8ef09a0a71 output/osx: don't use C99 designated initializers
Fixes `-Wpedantic`.
2020-07-01 17:34:06 +02:00
Max Kellermann e8044663b3 output/{alsa,osx}: use ConstBuffer::empty() 2020-07-01 17:32:37 +02:00
Max Kellermann 8444c33514 output/osx: don't use variable-length arrays 2020-07-01 17:31:46 +02:00
Max Kellermann e709d9d15c Merge branch 'v0.21.x' 2020-07-01 17:29:39 +02:00
Max Kellermann 2b7328b434 output/osx: fix coding style 2020-07-01 17:11:02 +02:00
Max Kellermann e0e5ed62ee meson.build: defaults for "build.c_std" and "build.cpp_std"
Since Meson 0.51, there are special build options for "native:true"
builds, prefixed with "build.".  This change breaks cross builds
because `GenParseName.cxx` is no longer built with `-std=c++17`.

This patch adds defaults for "build.c_std" and "build.cpp_std".

Closes https://github.com/MusicPlayerDaemon/MPD/issues/890
2020-07-01 17:04:48 +02:00
Max Kellermann 3d7147390f Merge branch 'v0.21.x' 2020-07-01 16:56:17 +02:00
Max Kellermann ca705e1e37 python/build/meson.py: set BOOST_ROOT for Meson 0.54
Commit
08224dafcb
changed Meson to require BOOST_ROOT for cross builds.
2020-07-01 16:55:28 +02:00
Max Kellermann 3c5ef504f8 test/meson.build: add explicit dependency from run_output on libevent.a
We could exclude that feature if neither ALSA nor httpd are enabled,
but that's too complicated for this small debug program.
2020-07-01 15:26:02 +02:00
Max Kellermann 25b5ca6435 output/plugins/meson.build: add dependency on libevent.a for ALSA 2020-07-01 15:24:52 +02:00
Max Kellermann fd217daad4 meson.build: always write encoder/Features.h
Fixes a build failure in `CommandLine.cxx`.

Closes https://github.com/MusicPlayerDaemon/MPD/issues/905
2020-07-01 15:16:14 +02:00
Max Kellermann d9f9b3df10 input/file: detect premature end of file
A bug report (https://github.com/MusicPlayerDaemon/MPD/issues/912)
suggests that on Linux, reading on `cifs` files may rarely return 0 (=
end of file) before the end of the file has really been reached.  But
that's just a theory which I need to validate, so this runtime check
shall catch this condition before the assertion in
DecoderBridge::Read() crashes MPD.  Let's see.

Closes https://github.com/MusicPlayerDaemon/MPD/issues/912
2020-07-01 15:14:27 +02:00
Max Kellermann a43ee97746 util/UriUtil: strip credentials from smb:// URIs
Closes https://github.com/MusicPlayerDaemon/MPD/issues/910
2020-06-22 22:48:56 +02:00
Max Kellermann 43c32372e7 util/UriUtil: make `schemes` array static 2020-06-22 22:48:07 +02:00
Max Kellermann 5716cde1fb queue/PlaylistEdit: fix crash in SetSongIdRange() while playing
An assertion failure in UpdateQueuedSong() could trigger because the
`prev` parameter is always `nullptr`, but `queued` may be set.  And in
fact, calling UpdateQueuedSong() is only necessary when the queued
song was edited, to re-queue it with the new range.

Closes https://github.com/MusicPlayerDaemon/MPD/issues/901
2020-06-11 07:07:02 +02:00
Max Kellermann b7a99b4a4b increment version number to 0.21.25 2020-06-11 06:29:08 +02:00
Max Kellermann c6a7f6dabc release v0.21.24
-----BEGIN PGP SIGNATURE-----
 
 iQJEBAABCgAuFiEEA5IzWngIOJSkMBxDI26KWMbbRRIFAl7hRzQQHG1heEBtdXNp
 Y3BkLm9yZwAKCRAjbopYxttFEp7dD/483fkBEyipufQyQT9nntP8R/vqKlUT+M9V
 8LyoJBtNtbNkO4bdrgAQCzElYzkDnd8VR++ZDEcqSEF49y5wafsiuufJNW2/s02Y
 ygAqgTCpcuS58F7aK92CW99bhZcKC6zoQovkenSMaZ39gorE1ZuO1JyrFR1LWOat
 ELekougQe0JbX2YX0YOH0Qags5fv9joxYJYsx8ZC60sCRNc+h8CBQjpyhZqzk7wC
 EPviLeMDw5lXkoSI3C045QmwJRFG8GMEyZ/4E/mnibxoTXBJmsm4ArKrfJznrUUs
 r8Mkf4G7sVqbsRMyMFBpzw+lsRDpVWI26mhdah9Y1zuUYPaEMe7OVKuEsASJQ/oK
 33wRSBVZc7EPhV3m8f7U8NAJI0/XaaPKGgP2OrtnOfxD+OyAze4vNLZ/GJCYSsh+
 wN1grmJw1mTP52xBicN2AITqXSVVpuvznn+p0g9MBB9Nw8/vbeWaqGPQhMHGHW6a
 JIL9yUTWwhkvkhav1bT7zKaeZv3qfgO7fjkgJqQFYt/q4FZwPFHJme55mVGq9d1y
 FNR8BMh+0A8hRhhQVwVycLxr4+NJja3vaqx+uVG2kov1g3eQBSgnEYCiEV7uls4V
 Pr4sIEeU/QQ+0jsMoJCaW65bNm4tOGKibpjSHrwJ+gxwKn3N7sJaAOo7PgGsUZyS
 30cBC5zkjw==
 =XHev
 -----END PGP SIGNATURE-----

Merge tag 'v0.21.24'

release v0.21.24
2020-06-10 22:58:41 +02:00
Max Kellermann 24741c5d06 release v0.21.24 2020-06-10 22:48:50 +02:00
Max Kellermann 6b3a282db4 lib/curl/Request: don't enable CURLOPT_NETRC on Windows
Our Windows build is built with `--disable-netrc`, and that makes
CURLOPT_NETRC fail, causing failures with all streams.  D'oh!

Closes https://github.com/MusicPlayerDaemon/MPD/issues/886
2020-06-10 22:46:42 +02:00
Max Kellermann 7583cfe9b7 {android,win32}/build.py: enable the GME decoder plugin
Closes https://github.com/MusicPlayerDaemon/MPD/issues/891
2020-06-10 21:33:29 +02:00
Max Kellermann aafc9ce75b decoder/gme: use class NarrowPath() for Windows compatibility 2020-06-10 21:22:00 +02:00
Max Kellermann fea326530b decoder/gme: simplify LoadGmeAndM3u() by moving code to ReplaceSuffix() 2020-06-10 21:20:49 +02:00
Max Kellermann 8925cc17d8 decoder/gme: use StringAfterPrefix() 2020-06-10 21:11:08 +02:00
Max Kellermann 14412c867f add a few IWYU pragmas 2020-06-10 21:10:33 +02:00
Max Kellermann c5cc256bf2 decoder/gme: use Path::GetSuffix() 2020-06-10 21:02:07 +02:00
Max Kellermann 563c7318f9 fs/AllocatedPath: add method GetSuffix() 2020-06-10 21:00:41 +02:00
Max Kellermann e92129f449 doc/protocol.rst: clarify the term "UNIX time"
Closes https://github.com/MusicPlayerDaemon/MPD/issues/893
2020-06-10 20:42:42 +02:00
Max Kellermann 96a273bf3b Merge branch 'misc/tar-python' of git://github.com/ibmibmibm/MPD 2020-06-10 17:54:22 +02:00
Max Kellermann 66c27d2c13 Merge branch 'document-idle-neighbor-mount' of git://github.com/naglis/MPD 2020-06-10 17:53:03 +02:00
Max Kellermann 374cc51f77 decoder/Bridge: add flag to make initial seek errors fatal
When the client wants to seek, but the decoder has already finished
decoding the current song, the player restarts the decoder with an
initial seek at the new position.  When this initial seek fails, MPD
pretends nothing has happened and plays this song from the start.

With this new flag, a restarted decoder marks the initial seek as
"essential" and fails the decoder if that seek fails.

Closes https://github.com/MusicPlayerDaemon/MPD/issues/895
2020-06-10 17:49:10 +02:00
Max Kellermann c031f9aa5d systemnd: configure LimitMEMLOCK for io_uring
The io_uring buffer is allocated as memlocked memory, as MPD needs to
be able to lock memory.
2020-06-09 21:09:00 +02:00
Max Kellermann 068006ebd7 decoder/Bridge: install an InputStreamHandler on local files
Before the advent of io_uring (commit dae8da7066), this didn't
matter, because the `FileInputStream` never called this.  But
`UringInputStream` is derived from `AsyncInputStream`, and needs the
handler to signal completion.

Closes https://github.com/MusicPlayerDaemon/MPD/issues/898
2020-06-09 21:07:38 +02:00
Naglis Jonaitis d2362b7c31
doc: document neighbor and mount idle subsystems 2020-06-07 16:43:04 +03:00
Shen-Ta Hsieh 9a4059ba39
misc: use python builtin tar library when /bin/tar not found 2020-06-05 11:22:52 +08:00
Max Kellermann 759f4231d2 meson.build: set default option default_library=static
For subprojects.
2020-06-04 18:44:47 +02:00
Max Kellermann 0cefb61a2e test/meson.build: install GTest from fallback Meson wrap 2020-06-04 14:56:43 +02:00
Max Kellermann b7ab1a9d79 test/meson.build: disable GTest warning "ScopedTrace was marked unused but was used" 2020-06-04 10:32:02 +02:00
Shen-Ta Hsieh d181ecce7b
macos: change CI xcode to 10.3 for c++17 support
c++17 is offered by default with Xcode 10
https://developer.apple.com/documentation/xcode_release_notes/xcode_10_release_notes
2020-06-04 08:35:02 +08:00
Shen-Ta Hsieh d2d53cc9d6
doc: add docs for wasapi plugin 2020-05-30 22:21:03 +08:00
Shen-Ta Hsieh 93d87854e9
src/output: add wasapi output and mixer plugin 2020-05-30 22:21:03 +08:00
Shen-Ta Hsieh e5eac71d72
win32: add COM helper classes 2020-05-30 22:21:03 +08:00
Max Kellermann f20b927858 Merge branch 'v0.21.x' 2020-05-30 14:05:18 +02:00
Rosen Penev e4dad42ca1 use std chr functions
The ones in std have overloads for const char/char.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2020-05-30 13:36:53 +02:00
Max Kellermann 99afe8e6d1 lib/icu/Win32: paranoid-ify the buffer length checks
Passing `length+1` to `MultiByteToWideChar()` means the function may
fill the whole buffer with output data, and could theoretically
overwrite the null terminator.  In practice, this will never happen,
but this way, it's slightly more correct.

Also, null-terminate after `MultiByteToWideChar()`, after we got the
real output length.  Again, this would never have been a problem, but
who knows...
2020-05-30 13:29:09 +02:00
Rosen Penev 1008d5f67c use cwchar include
Needed for std::wmemchr under libcxx

Signed-off-by: Rosen Penev <rosenp@gmail.com>
2020-05-30 13:22:04 +02:00
Shen-Ta Hsieh 169810e8f4
lib/icu: add null terminate in win32 string and wstring 2020-05-30 04:04:34 +08:00
Shen-Ta Hsieh 8e07ea7ad8 src/db: fitting libmpdclient interface 2020-05-29 19:00:16 +02:00
Max Kellermann 9f5c6d29b2 output/osx: use range-based `for` 2020-05-28 15:59:52 +02:00
Max Kellermann f6823cc679 output/osx: move code to FindAudioDeviceByName() 2020-05-28 15:54:57 +02:00
Max Kellermann 69c0f0fe99 apple/AudioUnit: wrapper functions for AudioObject properties 2020-05-28 15:54:57 +02:00