X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=util%2Fepist%2Fparser.cc;h=f6ed589e4ed8449eb67b28e6e7339f63ccab1667;hb=73f6bb1a7b6bb5f8b9cf22587722d713a1f15b59;hp=5c953aaec39992acb343440d763724f2a4ad6d3c;hpb=8ea3db574ad4fc3e8022d89045b66d4fe2597356;p=chaz%2Fopenbox diff --git a/util/epist/parser.cc b/util/epist/parser.cc index 5c953aae..f6ed589e 100644 --- a/util/epist/parser.cc +++ b/util/epist/parser.cc @@ -54,9 +54,13 @@ void parser::parse(string rc_file) yyin = fopen(rc_file.c_str(), "r"); - yyparse(this); + if (yyin) { + yyparse(this); + fclose(yyin); + } else { + std::cerr << "ERROR: Configuration file could not be opened/found.\n"; + } - fclose(yyin); _kt->reset(); _kt->initialize(); }