summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/fabric_rpc.erl10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/fabric_rpc.erl b/src/fabric_rpc.erl
index 1a2edf77..948bc54b 100644
--- a/src/fabric_rpc.erl
+++ b/src/fabric_rpc.erl
@@ -203,7 +203,15 @@ group_info(DbName, Group0) ->
with_db(DbName, Options, {M,F,A}) ->
case couch_db:open(DbName, Options) of
{ok, Db} ->
- rexi:reply(apply(M, F, [Db | A]));
+ rexi:reply(try
+ apply(M, F, [Db | A])
+ catch Exception ->
+ Exception;
+ error:Reason ->
+ ?LOG_ERROR("~p ~p ~p~n~p", [?MODULE, {M,F}, Reason,
+ erlang:get_stacktrace()]),
+ {error, Reason}
+ end);
Error ->
rexi:reply(Error)
end.