# HG changeset patch # User Matthew Wild # Date 1264691130 0 # Node ID a81c710b17085f36a9b16344ccaf01144af8c934 # Parent 97b5ea975cb95e427ff7b6c73a4a0e9c03c0f554 prosodyctl: Don't display message about failing to start Prosody is daemonizing is disabled (if daemonizing is disabled then Prosody is stopped by the time control returns to prosodyctl, which then can't see Prosody running) diff -r 97b5ea975cb9 -r a81c710b1708 prosodyctl --- a/prosodyctl Thu Jan 28 14:56:47 2010 +0000 +++ b/prosodyctl Thu Jan 28 15:05:30 2010 +0000 @@ -341,21 +341,23 @@ local ok, ret = prosodyctl.start(); if ok then - local i=1; - while true do - local ok, running = prosodyctl.isrunning(); - if ok and running then - break; - elseif i == 5 then - show_message("Still waiting..."); - elseif i >= prosodyctl_timeout then - show_message("Prosody is still not running. Please give it some time or check your log files for errors."); - return 2; + if config.get("*", "core", "daemonize") ~= false then + local i=1; + while true do + local ok, running = prosodyctl.isrunning(); + if ok and running then + break; + elseif i == 5 then + show_message("Still waiting..."); + elseif i >= prosodyctl_timeout then + show_message("Prosody is still not running. Please give it some time or check your log files for errors."); + return 2; + end + socket.sleep(0.5); + i = i + 1; end - socket.sleep(0.5); - i = i + 1; + show_message("Started"); end - show_message("Started"); return 0; end