summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLuke Bakken <lbakken@pivotal.io>2017-10-25 09:07:36 -0700
committerLuke Bakken <lbakken@pivotal.io>2017-10-25 09:16:02 -0700
commit1711dd0bcaedd7a1b34f05e9d2f40285f621941a (patch)
treedac35cc1fd6ee2ae58e7b5f36bca409d9d530655 /src
parent17a4876ac410abe6ba306ef568fa5838010fc7a8 (diff)
downloadrabbitmq-server-git-1711dd0bcaedd7a1b34f05e9d2f40285f621941a.tar.gz
Review changes
Diffstat (limited to 'src')
-rw-r--r--src/rabbit_control_main.erl22
1 files changed, 8 insertions, 14 deletions
diff --git a/src/rabbit_control_main.erl b/src/rabbit_control_main.erl
index 9bd4f2568e..fe9777a07d 100644
--- a/src/rabbit_control_main.erl
+++ b/src/rabbit_control_main.erl
@@ -289,14 +289,11 @@ shutdown_node_and_wait_pid_to_stop(Node, Pid, Inform) ->
% an RPC call to rabbit:stop_and_halt. We return error_during_shutdown
% so that rabbit_cli:main can differentiate this error from
% other badrpc errors
- {badrpc, {'EXIT', RpcErr0}} ->
- {error, {error_during_shutdown, RpcErr0}};
+ {badrpc, {'EXIT', RpcErr}} ->
+ {error, {error_during_shutdown, RpcErr}};
% NB: rabbit_cli:main pretty-prints other badrpc errors using
- % rabbit_nodes:diagnostics, so don't modify the error here
- {badrpc, _}=RpcErr1 ->
- RpcErr1;
- Error ->
- {error, {error_during_shutdown, Error}}
+ % rabbit_nodes:diagnostics, so don't modify the error here.
+ Error -> Error
end.
action(shutdown, Node, [], _Opts, Inform) ->
@@ -307,14 +304,11 @@ action(shutdown, Node, [], _Opts, Inform) ->
% rpc:call. We return error_during_shutdown so that
% rabbit_cli:main can differentiate this error from other badrpc
% errors
- {badrpc, {'EXIT', RpcErr0}} ->
- {error, {error_during_shutdown, RpcErr0}};
+ {badrpc, {'EXIT', RpcErr}} ->
+ {error, {error_during_shutdown, RpcErr}};
% NB: rabbit_cli:main pretty-prints other badrpc errors using
- % rabbit_nodes:diagnostics, so don't modify the error here
- {badrpc, _}=RpcErr1 ->
- RpcErr1;
- Error ->
- {error, {error_during_shutdown, Error}}
+ % rabbit_nodes:diagnostics, so don't modify the error here.
+ Error -> Error
end;
action(stop, Node, Args, _Opts, Inform) ->