aboutsummaryrefslogtreecommitdiff
path: root/Assistant/Threads
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2012-11-11 15:42:03 -0400
committerGravatar Joey Hess <joey@kitenet.net>2012-11-11 15:42:03 -0400
commit0d21e323e0d095232e347859adaaf2cc2cd71592 (patch)
tree6edb70e3e315926f1a226d30e6e12755c94d3d84 /Assistant/Threads
parent2aa6505378c3789da0cf78c784467c67fd9d593c (diff)
allow both one push and one receive-pack to run at the same time
Noticed that when pairing, sometimes both sides start to push, and the other side sends a PushRequest, and the two deadlock, neither doing anything. (Timeout eventually breaks this.) So, let both run at the same time.
Diffstat (limited to 'Assistant/Threads')
-rw-r--r--Assistant/Threads/XMPPClient.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/Assistant/Threads/XMPPClient.hs b/Assistant/Threads/XMPPClient.hs
index 12ec9d550..8df9ff04e 100644
--- a/Assistant/Threads/XMPPClient.hs
+++ b/Assistant/Threads/XMPPClient.hs
@@ -99,7 +99,7 @@ xmppClient urlrenderer d = do
handle _ (GotNetMessage m@(Pushing _ pushstage))
| isPushInitiation pushstage = inAssistant $
unlessM (queueNetPushMessage m) $
- void $ forkIO <~> handlePushMessage m
+ void $ forkIO <~> handlePushInitiation m
| otherwise = void $ inAssistant $ queueNetPushMessage m
handle _ (Ignorable _) = noop
handle _ (Unknown _) = noop