Browse Source

Catch exceptions in ranch_conns_sup:active_connections/1

It can be called from other nodes too.
Loïc Hoguin 12 years ago
parent
commit
033afb1a44
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/ranch_conns_sup.erl

+ 1 - 1
src/ranch_conns_sup.erl

@@ -75,7 +75,7 @@ start_protocol(SupPid, Socket) ->
 -spec active_connections(pid()) -> non_neg_integer().
 active_connections(SupPid) ->
 	Tag = erlang:monitor(process, SupPid),
-	erlang:send(SupPid, {?MODULE, active_connections, self(), Tag},
+	catch erlang:send(SupPid, {?MODULE, active_connections, self(), Tag},
 		[noconnect]),
 	receive
 		{Tag, Ret} ->