From 811b2095f8316260e38e6ee58937e04219952f97 Mon Sep 17 00:00:00 2001 From: Simon MacMullen Date: Thu, 24 May 2012 16:41:48 +0100 Subject: Add special case for i18n reasons. --- src/rabbit_control.erl | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/rabbit_control.erl b/src/rabbit_control.erl index 2a84f7b2..ad350d28 100644 --- a/src/rabbit_control.erl +++ b/src/rabbit_control.erl @@ -156,6 +156,11 @@ start() -> {'EXIT', {badarg, _}} -> print_error("invalid parameter: ~p", [Args]), usage(); + {error, {Problem, Reason}} when is_atom(Problem); is_binary(Reason) -> + %% We handle this common case specially to avoid ~p since + %% that has i18n issues + print_error("~s: ~s", [Problem, Reason]), + rabbit_misc:quit(2); {error, Reason} -> print_error("~p", [Reason]), rabbit_misc:quit(2); -- cgit v1.2.1