From a9648ac8e3d2b4123439a93f8cfe0a671e3e6fe9 Mon Sep 17 00:00:00 2001 From: Waqas Hussain Date: Mon, 3 Aug 2009 21:48:51 +0500 Subject: Fixed: Self-references could be added to rosters via presence subscriptions --- plugins/mod_presence.lua | 1 + 1 file changed, 1 insertion(+) (limited to 'plugins') diff --git a/plugins/mod_presence.lua b/plugins/mod_presence.lua index a077d7bd..02ec6f79 100644 --- a/plugins/mod_presence.lua +++ b/plugins/mod_presence.lua @@ -165,6 +165,7 @@ end function handle_outbound_presence_subscriptions_and_probes(origin, stanza, from_bare, to_bare, core_route_stanza) local node, host = jid_split(from_bare); + if node == origin.username and host == origin.host then return; end -- No self contacts local st_from, st_to = stanza.attr.from, stanza.attr.to; stanza.attr.from, stanza.attr.to = from_bare, to_bare; log("debug", "outbound presence "..stanza.attr.type.." from "..from_bare.." for "..to_bare); -- cgit v1.2.3