summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemko Tronçon <git@el-tramo.be>2009-07-19 13:48:19 (GMT)
committerRemko Tronçon <git@el-tramo.be>2009-07-19 13:48:19 (GMT)
commit958fe81b045e54ed6dadfe1fa9b14ac317811abf (patch)
tree4d341a6780bafb187d8aa753de71582f68949da0 /Swiften/Session
parenta6fcd9e7aa12c5e00c61ff809e81fba14babd70c (diff)
downloadswift-contrib-958fe81b045e54ed6dadfe1fa9b14ac317811abf.zip
swift-contrib-958fe81b045e54ed6dadfe1fa9b14ac317811abf.tar.bz2
Factor out common code from ServerFromClientSession.
Diffstat (limited to 'Swiften/Session')
-rw-r--r--Swiften/Session/Session.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/Swiften/Session/Session.cpp b/Swiften/Session/Session.cpp
index 84354e5..5ee98e7 100644
--- a/Swiften/Session/Session.cpp
+++ b/Swiften/Session/Session.cpp
@@ -42,10 +42,10 @@ void Session::initializeStreamStack() {
xmppLayer = boost::shared_ptr<XMPPLayer>(
new XMPPLayer(payloadParserFactories, payloadSerializers));
xmppLayer->onStreamStart.connect(
- boost::bind(&Session::handleStreamStart, this, _1));
- xmppLayer->onElement.connect(boost::bind(&Session::handleElement, this, _1));
+ boost::bind(&Session::handleStreamStart, shared_from_this(), _1));
+ xmppLayer->onElement.connect(boost::bind(&Session::handleElement, shared_from_this(), _1));
xmppLayer->onError.connect(
- boost::bind(&Session::finishSession, this, XMLError));
+ boost::bind(&Session::finishSession, shared_from_this(), XMLError));
xmppLayer->onDataRead.connect(boost::bind(boost::ref(onDataRead), _1));
xmppLayer->onWriteData.connect(boost::bind(boost::ref(onDataWritten), _1));
connection->onDisconnected.connect(