diff options
author | Remko Tronçon <git@el-tramo.be> | 2010-06-18 21:17:26 (GMT) |
---|---|---|
committer | Remko Tronçon <git@el-tramo.be> | 2010-06-18 21:27:59 (GMT) |
commit | 154bf14ac15fc7bff918c20814b29b5cc3bc5ba4 (patch) | |
tree | 28f18493bb6bc1cbf85b90f391daa6c4e1ecb3aa /Limber | |
parent | b763087e13f25e08aa51a6568b03727f136de34e (diff) | |
download | swift-contrib-154bf14ac15fc7bff918c20814b29b5cc3bc5ba4.zip swift-contrib-154bf14ac15fc7bff918c20814b29b5cc3bc5ba4.tar.bz2 |
Fix crash on reconnect.
BoostTimer isn't supposed to be constructed as a non-shared-ptr. Making
constructor private to avoid this error in the future.
Diffstat (limited to 'Limber')
-rw-r--r-- | Limber/.gitignore | 1 | ||||
-rw-r--r-- | Limber/main.cpp | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/Limber/.gitignore b/Limber/.gitignore index 6c52f38..b095d75 100644 --- a/Limber/.gitignore +++ b/Limber/.gitignore @@ -1 +1,2 @@ limber +BuildVersion.h diff --git a/Limber/main.cpp b/Limber/main.cpp index 5719a8c..45c6931 100644 --- a/Limber/main.cpp +++ b/Limber/main.cpp @@ -30,7 +30,7 @@ using namespace Swift; class Server { public: Server(UserRegistry* userRegistry) : userRegistry_(userRegistry) { - serverFromClientConnectionServer_ = boost::shared_ptr<BoostConnectionServer>(new BoostConnectionServer(5222, &boostIOServiceThread_.getIOService())); + serverFromClientConnectionServer_ = BoostConnectionServer::create(5222, &boostIOServiceThread_.getIOService()); serverFromClientConnectionServer_->onNewConnection.connect(boost::bind(&Server::handleNewConnection, this, _1)); serverFromClientConnectionServer_->start(); } |