Commit Graph

18975 Commits

Author SHA1 Message Date
Max Kellermann a0825e6ce0 net/PeerCredentials: add getpeereid() support 2025-01-29 19:28:09 +01:00
Max Kellermann c7621ec0e4 net/PeerCredentials: wrapper for struct ucred 2025-01-29 19:28:03 +01:00
Max Kellermann 2c7ca16c4e lib/fmt/ToBuffer: add constexpr 2025-01-29 18:12:08 +01:00
Max Kellermann ad8c2577c4 util/PackedBigEndian: add class PackedSignedBE16 2025-01-29 18:11:47 +01:00
Max Kellermann 7c9a460786 io/uring/Ring: add method SetMaxWorkers() 2025-01-29 18:10:59 +01:00
Max Kellermann c644b7616a io/uring/Ring: add ctor wrapping io_uring_queue_init_params() 2025-01-29 18:10:20 +01:00
Max Kellermann badf7101e2 io/uring/Ring: use if with initializer 2025-01-29 18:10:04 +01:00
Max Kellermann 6fb91e661c io/uring/Queue: DispatchCompletions() returns bool 2025-01-29 18:09:57 +01:00
Max Kellermann ed819a05e3 io/uring/Ring: add SubmitAndGetEvents() 2025-01-29 18:09:52 +01:00
Max Kellermann 2e3a51a5da io/uring/Close: use IOSQE_CQE_SKIP_SUCCESS
We don't want to get any completion events for "close".  It's
fire-and-forget.
2025-01-29 18:09:29 +01:00
Max Kellermann e682940c54 event/PipeEvent: add GetScheduledFlags(), [GS]etReadyFlags() 2025-01-29 18:09:10 +01:00
Max Kellermann fa375cbaeb event/uring/Manager: un-inline the ctor 2025-01-29 18:09:06 +01:00
Max Kellermann 3f638bfa03 io/uring/Operation: add method GetUringData() 2025-01-29 18:07:55 +01:00
Max Kellermann 0ba0c64093 event/uring/Manager: add flags parameter 2025-01-29 18:07:46 +01:00
Max Kellermann 5e107c33d9 event/DeferEvent: add ScheduleNext() 2025-01-29 18:05:50 +01:00
Max Kellermann 4bb379a218 event/ServerSocket: use SocketDescriptor::GetPeerCredentials() 2025-01-29 17:56:26 +01:00
Max Kellermann 3710b54d43 event/ServerSocket: pass SocketDescriptor to get_remote_uid() 2025-01-29 17:56:26 +01:00
Max Kellermann 70f1f9cff8 subprojects: update gtest to 1.15.2 2025-01-29 17:41:24 +01:00
Max Kellermann 9787d39c3f subprojects: update expat to 2.6.4 2025-01-29 17:41:11 +01:00
Max Kellermann 54527068d5 .github/workflows/build.yml: fix matrix name
Regression by commit ab011adf77
2025-01-29 17:35:33 +01:00
Max Kellermann 0186f73c7a client/Process: let libfmt quote the command string 2025-01-29 17:32:42 +01:00
gd 88594c81d6 Logging: added seconds to log time string.
Time was only in minutes before.
Seconds is more useful in analyzing the log for example
with issues of timeouts, and reponse times.
2025-01-29 17:31:21 +01:00
Max Kellermann f6bd49ba61 Merge branch 'tag-compare' of https://github.com/geneticdrift/MPD 2025-01-29 17:21:54 +01:00
Max Kellermann a404e5754e Merge tag 'v0.23.17'
release v0.23.17
2025-01-29 17:20:02 +01:00
Max Kellermann b080ca8627 release v0.23.17 2025-01-29 17:11:53 +01:00
Max Kellermann 0e8cd3b961 client/Process: explicitly disallow "idle" and "noidle" in command lists
These commands cannot possibly work with command lists because command
lists are supposed to be atomic, but suspended command execution
conflicts with that.

Closes https://github.com/MusicPlayerDaemon/MPD/issues/2167
2025-01-29 17:08:53 +01:00
Max Kellermann 8fcb6e148f decoder/list: probe "ffmpeg" before "sndfile" and "audiofile"
For FFmpeg's DTS-WAV support, see code comment.

Closes https://github.com/MusicPlayerDaemon/MPD/issues/2158
2025-01-29 15:42:54 +01:00
gd ce9ee38304 decoder/Bridge: DecoderBridge::UpdateStreamTag - return false if stream tag not changed.
Some streams send the same tags frequently, causeing unnecessary update
events.
2025-01-29 16:02:20 +02:00
gd f9d47502d8 player/Thread: update song tag from remote stream only if changed.
Some streams send the same tags frequently, causing unnecessary player queue update events.
2025-01-29 16:00:37 +02:00
gd f15014b6af tag/Item: made TagItem constructor private and friend TagPoolItem
To only allow construction as part of TagPoolItem with its special var size allocator in TagPoolItem::Create.
2025-01-29 16:00:37 +02:00
gd 2a9c3a2e50 tag/Tag: added operator==(Tag&) 2025-01-29 16:00:37 +02:00
gd 3e9c2cce71 tag/Item: added operator== to TagItem 2025-01-29 16:00:37 +02:00
gd 93bf99f639 util/DereferenceIterator, TerminatedArray: added operator-(const IteratorType&) to DereferenceIterator and TerminatedArray::iterator
It is required by std::distance and some std algos.
2025-01-29 16:00:20 +02:00
Max Kellermann c0a9434f34 command/file: "albumart" tries to send larger chunks if available
If we only receive very little data from the InputStream, try a second
Read() call to get more data.  This works around tiny reads at input
buffer boundaries with the io_uring input plugin.  These tiny reads
are inefficient, and we can afford to wait one more low-level I/O
iteration to finish (but not more).

Closes https://github.com/MusicPlayerDaemon/MPD/issues/2186
2025-01-29 13:07:05 +01:00
Max Kellermann d7212624b0 input/{async,thread}: clear the CircularBuffer when it becomes empty
First step towards fixing https://github.com/MusicPlayerDaemon/MPD/issues/2186
2025-01-29 13:05:24 +01:00
Max Kellermann 70a0a781c8 input/async: move the IsEOF() check to a separate block 2025-01-29 12:59:04 +01:00
Max Kellermann ab011adf77 meson.build: require GCC 12 or clang 14
GCC 10 doesn't have std::make_unique_for_overwrite(), so let's drop it.
2025-01-29 12:24:48 +01:00
Max Kellermann 8ea3f86f43 Revert "meson.build: disable -Wsuggest-override with GCC 8"
This reverts commit 56c0733b42.  GCC 8
is no longer supported.
2025-01-29 12:22:11 +01:00
Max Kellermann bd78307940 input/{async,thread}: add an additional Cond field
This eliminates the ScopeExchangeInputStreamHandler kludge.
2025-01-29 12:14:42 +01:00
Max Kellermann 3cc7b7dbf9 Merge branch 'v0.23.x' 2025-01-29 12:09:18 +01:00
Max Kellermann 57e7fb3f62 tag/Id3Load, ...: use std::make_unique_for_overwrite()
Don't zero-initialize the buffers.  This removes some useless
overhead.
2025-01-29 12:01:27 +01:00
Max Kellermann 687475cf3c db/update/InotifyUpdate: handle IN_CREATE without IN_ISDIR
A new symlink causes `IN_CREATE`.  Usually, we catch `IN_CREATE` only with
IN_ISDIR to watch the new directory, but otherwise `IN_CREATE` is not
handled.  Regular files are "created" but they have usable content
only with `IN_CLOSE_WRITE`.  Yet symlinks have only `IN_CREATE` and
they are immediately usable.

Closes https://github.com/MusicPlayerDaemon/MPD/issues/2192
2025-01-29 09:41:08 +01:00
Max Kellermann c48dbd5dd4 lib/nfs/meson.build: reject libnfs 6
libnfs version 6 has major API changes and MPD 0.23 has never been
adapted to these.  This additional configure-time check fixes
potential compile-time failures.
2025-01-29 09:04:55 +01:00
Max Kellermann 37049aab36 lib/nfs/Connection: remove EnableCloseOnExec() call
SOCK_CLOEXEC has been added to libnfs version 2, and since we require
at least version 4, we can safely remove this call.
2025-01-29 09:02:05 +01:00
Max Kellermann 18495fbb4e lib/nfs/meson.build: require libnfs 4.0
All Linux distributions have at least version 4, and thus I cannot
test with older versions.
2025-01-29 09:00:37 +01:00
Max Kellermann cdcee16738 client/File: improve error message
Users are confused by "Access denied".  Let's write an error message
that is more clear.

Closes https://github.com/MusicPlayerDaemon/MPD/issues/2184
2025-01-29 08:28:30 +01:00
Max Kellermann 83c2d9c964 test/meson.build: add another missing dependency on libevent.a
Necessary for including Client.hxx.
2025-01-28 19:52:25 +01:00
Max Kellermann 074a041760 test/meson.build: add missing dependencies on libevent.a 2025-01-28 19:47:36 +01:00
Max Kellermann 083d39ea80 decoder/plugins/meson.build: add missing dependency to libid3tag 2025-01-28 19:38:50 +01:00
Max Kellermann a5da7fd51a Merge branch 'v0.23.x' 2025-01-28 19:33:19 +01:00