From ed2a18569a68d5be78d5a893d66979eef9fe06cd Mon Sep 17 00:00:00 2001 From: Max Horn Date: Fri, 19 Aug 2005 17:27:47 +0000 Subject: Detect when plugins directory is missing svn-id: r18703 --- base/plugins.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'base') diff --git a/base/plugins.cpp b/base/plugins.cpp index 8f99157322..3af0954719 100644 --- a/base/plugins.cpp +++ b/base/plugins.cpp @@ -273,6 +273,9 @@ void PluginManager::loadPlugins() { // Load all plugins. // Scan for all plugins in this directory FilesystemNode dir(PLUGIN_DIRECTORY); + if (!dir.isValid() || !dir.isDirectory()) { + error("Couldn't open plugin directory '%s'", PLUGIN_DIRECTORY); + } FSList files(dir.listDir(FilesystemNode::kListFilesOnly)); for (FSList::const_iterator i = files.begin(); i != files.end(); ++i) { -- cgit v1.2.3