diff options
author | Vegard Storheil Eriksen <zyp@jvnv.net> | 2010-12-09 22:53:05 +0100 |
---|---|---|
committer | Vegard Storheil Eriksen <zyp@jvnv.net> | 2010-12-09 22:53:05 +0100 |
commit | a7c44e2839fabfe55a488a74f2031b3ffbaf7989 (patch) | |
tree | 44175261315e630b0baa4c44e6738b015fc5f456 /server | |
parent | 2ce64cf1b7b8d9742b5098b2e2cc425528bbdf55 (diff) |
Retry waiting for a Ready message if wrong message was received.
Diffstat (limited to 'server')
-rw-r--r-- | server/client.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/server/client.cpp b/server/client.cpp index aa0cdb7..2155359 100644 --- a/server/client.cpp +++ b/server/client.cpp @@ -84,6 +84,8 @@ void Client::handle_lobby(Message::p msg, boost::function<void (int)> lobby_call void Client::handle_ready(Message::p msg, boost::function<void ()> ready_callback) { if(msg->type != Message::Types::Ready) { + // Wait for another message. + connection->recv(boost::bind(&Client::handle_ready, shared_from_this(), _1, ready_callback)); return; } |