From 20c37dd67deaa52f32ab7cde142c0dc91db57650 Mon Sep 17 00:00:00 2001 From: Jonas Suhr Christensen Date: Wed, 15 May 2013 19:37:34 +0200 Subject: Skipping filtering of file with length less than drumkit suffix length. --- plugingui/directory.cc | 1 + 1 file changed, 1 insertion(+) (limited to 'plugingui') diff --git a/plugingui/directory.cc b/plugingui/directory.cc index 9053f8d..dfd6fcb 100644 --- a/plugingui/directory.cc +++ b/plugingui/directory.cc @@ -153,6 +153,7 @@ Directory::EntryList Directory::listFiles(std::string path) } else { int drumkit_suffix_length = strlen(DRUMKIT_SUFFIX); + if((int)name.size() < drumkit_suffix_length) continue; if(name.substr(name.length() - drumkit_suffix_length, drumkit_suffix_length) != DRUMKIT_SUFFIX) { continue; -- cgit v1.2.3