diff options
| author | Simon MacMullen <simon@rabbitmq.com> | 2010-11-15 11:25:25 +0000 |
|---|---|---|
| committer | Simon MacMullen <simon@rabbitmq.com> | 2010-11-15 11:25:25 +0000 |
| commit | ebf653fcbc58990f18ebb1f26d0f0e661b0fd513 (patch) | |
| tree | 810ca8af267df1983f8498f970d751f20a9d7132 | |
| parent | 03ee535c4fccb9b895289a352ab335624b9cb662 (diff) | |
| download | rabbitmq-server-git-ebf653fcbc58990f18ebb1f26d0f0e661b0fd513.tar.gz | |
Replace catch with try; we want to show all kinds of boot errors in a readable way.
| -rw-r--r-- | src/rabbit.erl | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/rabbit.erl b/src/rabbit.erl index a1dd2c2e40..983a845367 100644 --- a/src/rabbit.erl +++ b/src/rabbit.erl @@ -291,11 +291,10 @@ run_boot_step({StepName, Attributes}) -> io:format("-- ~s~n", [Description]); MFAs -> io:format("starting ~-60s ...", [Description]), - [case catch apply(M,F,A) of - {'EXIT', Reason} -> - boot_error("FAILED~nReason: ~p~n", [Reason]); - ok -> - ok + [try + apply(M,F,A) + catch + _:Reason -> boot_error("FAILED~nReason: ~p~n", [Reason]) end || {M,F,A} <- MFAs], io:format("done~n"), ok |
