From 20544fb077beae2ec25eadf73292f091207f1ad2 Mon Sep 17 00:00:00 2001 From: "Matthias P. Braendli" Date: Fri, 10 Apr 2015 09:09:03 +0200 Subject: Add detail when config file parser fails --- src/DabMod.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/DabMod.cpp b/src/DabMod.cpp index 83802ab..75e76e0 100644 --- a/src/DabMod.cpp +++ b/src/DabMod.cpp @@ -351,7 +351,8 @@ int main(int argc, char* argv[]) } catch (boost::property_tree::ini_parser::ini_parser_error &e) { - fprintf(stderr, "Error, cannot read configuration file '%s'\n", configuration_file.c_str()); + std::cerr << "Error, cannot read configuration file '" << configuration_file.c_str() << "'" << std::endl; + std::cerr << " " << e.what() << std::endl; throw std::runtime_error("Cannot read configuration file"); } -- cgit v1.2.3