From cbea31ab68752dfd3b66a9d4c995acc78295d209 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mickae=CC=88l=20Re=CC=81mond?= Date: Fri, 20 Mar 2015 11:42:32 +0100 Subject: [PATCH] Ignore errors when retrieving status if the users just got offline Fix possible race condition. --- mod_admin_extra/src/mod_admin_extra.erl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mod_admin_extra/src/mod_admin_extra.erl b/mod_admin_extra/src/mod_admin_extra.erl index 7729d89..ee5880d 100644 --- a/mod_admin_extra/src/mod_admin_extra.erl +++ b/mod_admin_extra/src/mod_admin_extra.erl @@ -836,7 +836,7 @@ get_status_list(Host, Status_required) -> end, Sessions3 = [ {Pid, Server, Priority} || {{_User, Server, _Resource}, {_, Pid}, Priority} <- Sessions2, apply(Fhost, [Server, Host])], %% For each Pid, get its presence - Sessions4 = [ {ejabberd_c2s:get_presence(Pid), Server, Priority} || {Pid, Server, Priority} <- Sessions3], + Sessions4 = [ {catch ejabberd_c2s:get_presence(Pid), Server, Priority} || {Pid, Server, Priority} <- Sessions3], %% Filter by status Fstatus = case Status_required of <<"all">> ->