From 0126276e2f2097cda2efe2e7d688c2c557cc9638 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Mon, 21 Jan 2019 22:21:11 +0100 Subject: [PATCH] FileCommands: log irregular errors while looking for cover art --- src/command/FileCommands.cxx | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/command/FileCommands.cxx b/src/command/FileCommands.cxx index 9b3d7417d..c0e88abff 100644 --- a/src/command/FileCommands.cxx +++ b/src/command/FileCommands.cxx @@ -37,9 +37,11 @@ #include "fs/FileInfo.hxx" #include "fs/DirectoryReader.hxx" #include "input/InputStream.hxx" +#include "input/Error.hxx" #include "LocateUri.hxx" #include "TimePrint.hxx" #include "thread/Mutex.hxx" +#include "Log.hxx" #include #include /* for PRIu64 */ @@ -257,6 +259,9 @@ find_stream_art(const char *directory, Mutex &mutex) try { return InputStream::OpenReady(art_file.c_str(), mutex); } catch (...) { + auto e = std::current_exception(); + if (!IsFileNotFound(e)) + LogError(e); } } return nullptr;