diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/command/FileCommands.cxx | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/command/FileCommands.cxx b/src/command/FileCommands.cxx index 863c7170e..c8af5c19b 100644 --- a/src/command/FileCommands.cxx +++ b/src/command/FileCommands.cxx @@ -285,8 +285,11 @@ read_stream_art(Response &r, const char *uri, size_t offset) uint8_t buffer[CHUNK_SIZE]; size_t read_size; - is->Seek(offset); - read_size = is->Read(&buffer, CHUNK_SIZE); + { + const std::lock_guard<Mutex> protect(mutex); + is->Seek(offset); + read_size = is->Read(&buffer, CHUNK_SIZE); + } r.Format("size: %" PRIoffset "\n" "binary: %u\n", |