diff options
author | Othmar Gsenger <otti@anytun.org> | 2008-12-30 17:39:03 +0000 |
---|---|---|
committer | Othmar Gsenger <otti@anytun.org> | 2008-12-30 17:39:03 +0000 |
commit | 466c357aeafb7bb0c7ccce23abc2d2c67645cbca (patch) | |
tree | 4ab587f43676715482b78278830e706d0e88684e | |
parent | fixed windows endian include (diff) |
sync race condition work-arround (needs better fix!)
-rw-r--r-- | src/connectionParam.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/connectionParam.h b/src/connectionParam.h index 41df91c..c2c21cc 100644 --- a/src/connectionParam.h +++ b/src/connectionParam.h @@ -69,8 +69,12 @@ private: ar & seq_nr_; ar & remote_host; ar & remote_port; + PacketSourceEndpoint emptyEndpoint; UDPPacketSource::proto::endpoint endpoint(boost::asio::ip::address::from_string(remote_host), remote_port); - remote_end_ = endpoint; + //This is a workarround, against race condition in sync process + //TODO: find a better solution + if (endpoint != emptyEndpoint) + remote_end_ = endpoint; } }; |