aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2015-08-06 10:14:53 +0200
committerMax Kellermann <max@duempel.org>2015-08-06 10:14:53 +0200
commite0f55b9295a863b171d5cdc4315170c122b559a6 (patch)
treed604c806c1925431685123d4786f965169975d59 /src
parentccd83748f79df00a9a4c5bb6c772d98ab3fa3d3f (diff)
downloadmpd-e0f55b9295a863b171d5cdc4315170c122b559a6.tar.gz
mpd-e0f55b9295a863b171d5cdc4315170c122b559a6.tar.xz
mpd-e0f55b9295a863b171d5cdc4315170c122b559a6.zip
output/fifo: move the buffer into the loop
Diffstat (limited to '')
-rw-r--r--src/output/plugins/FifoOutputPlugin.cxx3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/output/plugins/FifoOutputPlugin.cxx b/src/output/plugins/FifoOutputPlugin.cxx
index f91cacb0f..c2310b98f 100644
--- a/src/output/plugins/FifoOutputPlugin.cxx
+++ b/src/output/plugins/FifoOutputPlugin.cxx
@@ -226,12 +226,11 @@ FifoOutput::Close()
inline void
FifoOutput::Cancel()
{
- char buf[FIFO_BUFFER_SIZE];
-
timer->Reset();
ssize_t bytes;
do {
+ char buf[FIFO_BUFFER_SIZE];
bytes = read(input, buf, FIFO_BUFFER_SIZE);
} while (bytes > 0 && errno != EINTR);