From 1acb9bcedbc97191aafd7a9d52e84986b916bf23 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Thu, 16 May 2019 22:34:11 +0200 Subject: [PATCH] input/buffering: close input if buffered completely --- src/input/BufferingInputStream.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/input/BufferingInputStream.cxx b/src/input/BufferingInputStream.cxx index 08e62ffb9..20676ba70 100644 --- a/src/input/BufferingInputStream.cxx +++ b/src/input/BufferingInputStream.cxx @@ -196,8 +196,8 @@ BufferingInputStream::RunThread() noexcept size_t new_offset = FindFirstHole(); if (new_offset == INVALID_OFFSET) { /* the file has been read completely */ - wake_cond.wait(lock); - continue; + input.reset(); + break; } /* seek to the first hole */