summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjoe <joe@jerkface.net>2013-10-08 17:53:44 -0400
committerjoe <joe@jerkface.net>2013-10-08 17:53:44 -0400
commit2758e4597ad5fa02272a1500581345d1339d2d79 (patch)
treef860d55bece6c12136ac8abacdf3f3cd827b40d8
parentf98bf3c8449c234dff3fc0d2295c9485eb5c40c8 (diff)
Handle address of LocalHost in peerAddr. Fixes local echo case.
-rw-r--r--Presence/XMPPTypes.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/Presence/XMPPTypes.hs b/Presence/XMPPTypes.hs
index 41ce07c2..06cfb563 100644
--- a/Presence/XMPPTypes.hs
+++ b/Presence/XMPPTypes.hs
@@ -239,7 +239,7 @@ parseAddressJID jid = do
239 239
240peerAddr :: Peer -> SockAddr 240peerAddr :: Peer -> SockAddr
241peerAddr (RemotePeer addr) = addr 241peerAddr (RemotePeer addr) = addr
242-- peerAddr LocalHost = throw exception 242peerAddr LocalHost = SockAddrInet6 0 (0 {- FlowInfo -}) (0,0,0,1) (0 {- ScopeID -})
243 243
244socketFamily (SockAddrInet _ _) = AF_INET 244socketFamily (SockAddrInet _ _) = AF_INET
245socketFamily (SockAddrInet6 _ _ _ _) = AF_INET6 245socketFamily (SockAddrInet6 _ _ _ _) = AF_INET6