From ff3aec0a341aa9e5f099d4901ebaea718e5de5f2 Mon Sep 17 00:00:00 2001 From: Lephenixnoir Date: Thu, 27 Feb 2020 15:11:42 +0100 Subject: [PATCH] library: do not try to load directories as data files --- lib/library.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/library.cpp b/lib/library.cpp index 5d4e4ea..ed42dd7 100644 --- a/lib/library.cpp +++ b/lib/library.cpp @@ -25,7 +25,10 @@ void Library::explore(std::string path) try { fs::recursive_directory_iterator it(path); - for(auto &file: it) load(file.path()); + for(auto &file: it) + { + if(!fs::is_directory(file)) load(file.path()); + } } catch(fs::filesystem_error &e) {