# HG changeset patch # User Matthew Wild <mwild1@gmail.com> # Date 1241538077 -3600 # Node ID ad7c1cefb8ebd93eff5a5c03216724e979de2fd8 # Parent 063036ac82b7c3a9dbd3c504562665a4cdda5a54# Parent 055cfdc96afaf98f58962fb7fe6f7eaf2aa7a4a2 Merge with 0.4 diff -r 063036ac82b7 -r ad7c1cefb8eb prosodyctl --- a/prosodyctl Tue May 05 16:17:40 2009 +0100 +++ b/prosodyctl Tue May 05 16:41:17 2009 +0100 @@ -92,6 +92,7 @@ ["invalid-hostname"] = "The given hostname is invalid"; ["no-password"] = "No password was supplied"; ["no-such-user"] = "The given user does not exist on the server"; + ["unable-to-save-data"] = "Unable to store, perhaps you don't have permission?"; }, { __index = function (t,k) return "Error: "..(tostring(k):gsub("%-", " "):gsub("^.", string.upper)); end }); hosts = {}; @@ -318,9 +319,10 @@ else show_message("Prosody is not running"); if not switched_user and current_uid ~= 0 then - print("\nNote: You will also see this if prosodyctl is not running under the same"); - print(" user account as Prosody. Try running as root (e.g. with 'sudo' in front) to"); - print(" gain access to Prosody's real status."); + print("\nNote:") + print(" You will also see this if prosodyctl is not running under"); + print(" the same user account as Prosody. Try running as root (e.g. "); + print(" with 'sudo' in front) to gain access to Prosody's real status."); end return 2 end diff -r 063036ac82b7 -r ad7c1cefb8eb util/prosodyctl.lua --- a/util/prosodyctl.lua Tue May 05 16:17:40 2009 +0100 +++ b/util/prosodyctl.lua Tue May 05 16:41:17 2009 +0100 @@ -19,7 +19,10 @@ return false, "invalid-hostname"; end - usermanager.create_user(user, password, host); + local ok = usermanager.create_user(user, password, host); + if not ok then + return false, "unable-to-save-data"; + end return true; end