Avoids to load a directory structure as a rules file

This commit is contained in:
Felipe Zimmerle
2017-05-02 16:42:22 -03:00
parent c97db2f361
commit 0e05b7bb8a
3 changed files with 16 additions and 2 deletions

View File

@@ -157,7 +157,7 @@ int Driver::parseFile(const std::string &f) {
std::ifstream t(f);
std::string str;
if (t.is_open() == false) {
if (utils::isFile(f) == false) {
m_parserError << "Failed to open the file: " << f << std::endl;
return false;
}