From c2484808b3f3e9c14e44ff3554d31e5ef22e50b7 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Wed, 27 Sep 2017 15:33:29 +0200 Subject: prosody, prosodyctl: Print the actual config file name used when a problem loading it was encountered (see #990) --- prosodyctl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'prosodyctl') diff --git a/prosodyctl b/prosodyctl index 3323b169..379ccf46 100755 --- a/prosodyctl +++ b/prosodyctl @@ -93,13 +93,13 @@ do print("\n"); print("**************************"); if level == "parser" then - print("A problem occured while reading the config file "..(CFG_CONFIGDIR or ".").."/prosody.cfg.lua"); + print("A problem occured while reading the config file "..filename); local err_line, err_message = tostring(err):match("%[string .-%]:(%d*): (.*)"); print("Error"..(err_line and (" on line "..err_line) or "")..": "..(err_message or tostring(err))); print(""); elseif level == "file" then print("Prosody was unable to find the configuration file."); - print("We looked for: "..(CFG_CONFIGDIR or ".").."/prosody.cfg.lua"); + print("We looked for: "..filename); print("A sample config file is included in the Prosody download called prosody.cfg.lua.dist"); print("Copy or rename it to prosody.cfg.lua and edit as necessary."); end -- cgit v1.2.3