stanza_router: workaround for a Pidgin bug which sets 'to' to the SRV result

Wed, 03 Jun 2009 21:27:32 +0500

author
Waqas Hussain <waqas20@gmail.com>
date
Wed, 03 Jun 2009 21:27:32 +0500
changeset 1294
39197fe5ae94
parent 1293
13dde33d5b87
child 1295
ead6d78d2217

stanza_router: workaround for a Pidgin bug which sets 'to' to the SRV result

core/stanza_router.lua file | annotate | diff | comparison | revisions
--- a/core/stanza_router.lua	Wed Jun 03 08:02:24 2009 +0500
+++ b/core/stanza_router.lua	Wed Jun 03 21:27:32 2009 +0500
@@ -134,6 +134,7 @@
 			end
 			if h.events.fire_event(event, {origin = origin, stanza = stanza}) then return; end
 		end
+		if host and not hosts[host] then host = nil; end -- workaround for a Pidgin bug which sets 'to' to the SRV result
 		modules_handle_stanza(host or origin.host or origin.to_host, origin, stanza);
 	end
 end

mercurial