diff --git a/src/lib/alsa/NonBlock.cxx b/src/lib/alsa/NonBlock.cxx index 66f291cae..a9e8f0506 100644 --- a/src/lib/alsa/NonBlock.cxx +++ b/src/lib/alsa/NonBlock.cxx @@ -42,13 +42,13 @@ AlsaNonBlockPcm::DispatchSockets(MultiSocketMonitor &m, auto *i = pfds; m.ForEachReturnedEvent([&i, end](SocketDescriptor s, unsigned events){ - if (i >= end) - return; + if (i >= end) + return; - i->fd = s.Get(); - i->events = i->revents = events; - ++i; - }); + i->fd = s.Get(); + i->events = i->revents = events; + ++i; + }); unsigned short dummy; int err = snd_pcm_poll_descriptors_revents(pcm, pfds, i - pfds, &dummy); @@ -87,13 +87,13 @@ AlsaNonBlockMixer::DispatchSockets(MultiSocketMonitor &m, auto *i = pfds; m.ForEachReturnedEvent([&i, end](SocketDescriptor s, unsigned events){ - if (i >= end) - return; + if (i >= end) + return; - i->fd = s.Get(); - i->events = i->revents = events; - ++i; - }); + i->fd = s.Get(); + i->events = i->revents = events; + ++i; + }); unsigned short dummy; snd_mixer_poll_descriptors_revents(mixer, pfds, i - pfds, &dummy); diff --git a/src/lib/alsa/NonBlock.hxx b/src/lib/alsa/NonBlock.hxx index 5d27e5d14..7c8eade59 100644 --- a/src/lib/alsa/NonBlock.hxx +++ b/src/lib/alsa/NonBlock.hxx @@ -1,8 +1,7 @@ // SPDX-License-Identifier: GPL-2.0-or-later // Copyright The Music Player Daemon Project -#ifndef MPD_ALSA_NON_BLOCK_HXX -#define MPD_ALSA_NON_BLOCK_HXX +#pragma once #include "event/Chrono.hxx" #include "util/ReusableArray.hxx" @@ -51,5 +50,3 @@ public: */ void DispatchSockets(MultiSocketMonitor &m, snd_mixer_t *mixer) noexcept; }; - -#endif