diff options
author | Matthias Radestock <matthias@rabbitmq.com> | 2012-08-08 05:25:40 +0100 |
---|---|---|
committer | Matthias Radestock <matthias@rabbitmq.com> | 2012-08-08 05:25:40 +0100 |
commit | f030fef7be26d69e149f47087588d5b2b1869394 (patch) | |
tree | aeabc29243b674f8626d029a7cac346a309d39d9 | |
parent | 9a72e8980bbabd97cd9ecbc37baa4c799dc64dd9 (diff) | |
download | rabbitmq-server-f030fef7be26d69e149f47087588d5b2b1869394.tar.gz |
exiting the VM from deep inside a function is uncool
-rw-r--r-- | src/rabbit_plugins.erl | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/rabbit_plugins.erl b/src/rabbit_plugins.erl index 3caa13d7..0d3dde8c 100644 --- a/src/rabbit_plugins.erl +++ b/src/rabbit_plugins.erl @@ -126,13 +126,13 @@ prepare_plugins(EnabledFile, PluginsDistDir, ExpandDir) -> %% Eliminate the contents of the destination directory case delete_recursively(ExpandDir) of ok -> ok; - {error, E} -> rabbit_misc:quit("Could not delete dir ~s (~p)", - [ExpandDir, E]) + {error, E} -> throw({error, {cannot_delete_plugins_expand_dir, + [ExpandDir, E]}}) end, case filelib:ensure_dir(ExpandDir ++ "/") of - ok -> ok; - {error, E2} -> rabbit_misc:quit("Could not create dir ~s (~p)", - [ExpandDir, E2]) + ok -> ok; + {error, E} -> throw({error, {cannot_create_plugins_expand_dir, + [ExpandDir, E]}}) end, [prepare_plugin(Plugin, ExpandDir) || Plugin <- ToUnpackPlugins]. |