summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMatthias Radestock <matthias@lshift.net>2010-02-03 17:00:34 +0000
committerMatthias Radestock <matthias@lshift.net>2010-02-03 17:00:34 +0000
commitf6c9404bc1977d7fbddde99d8f3916bcfb4bd1e8 (patch)
treeeafe14db855c46d6105453ca2fa0e65f19ef2b1a /src
parent4d0e6a11f8cad7268631e95a3afaac88304bbbdb (diff)
downloadrabbitmq-server-git-f6c9404bc1977d7fbddde99d8f3916bcfb4bd1e8.tar.gz
better error reporting
Don't mis-report errors on the remote end as "unable to connect" errors. The reason this didn't come up previously is that the function we call for close_connection is the first to fail with an 'EXIT' signal rather than a 'throw'.
Diffstat (limited to 'src')
-rw-r--r--src/rabbit_control.erl3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/rabbit_control.erl b/src/rabbit_control.erl
index 2a4c1f03c5..2c2c67a6fc 100644
--- a/src/rabbit_control.erl
+++ b/src/rabbit_control.erl
@@ -81,6 +81,9 @@ start() ->
{error, Reason} ->
error("~p", [Reason]),
halt(2);
+ {badrpc, {'EXIT', Reason}} ->
+ error("~p", [Reason]),
+ halt(2);
{badrpc, Reason} ->
error("unable to connect to node ~w: ~w", [Node, Reason]),
print_badrpc_diagnostics(Node),