summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/rabbit_control.erl14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/rabbit_control.erl b/src/rabbit_control.erl
index 180f4b2d..b1680d95 100644
--- a/src/rabbit_control.erl
+++ b/src/rabbit_control.erl
@@ -359,13 +359,13 @@ wait_for_application(Node, PidFile, Inform) ->
wait_for_application(Node, Pid).
wait_for_application(Node, Pid) ->
- case node_up(Node) of
- true -> ok;
- false -> case pid_up(Pid) of
- true -> timer:sleep(1000),
- wait_for_application(Node, Pid);
- false -> {error, {pid_went_away, Pid}}
- end
+ case pid_up(Pid) of
+ true -> case node_up(Node) of
+ true -> ok;
+ false -> timer:sleep(1000),
+ wait_for_application(Node, Pid)
+ end;
+ false -> {error, pid_not_running}
end.
wait_and_read_pid_file(PidFile) ->