summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemko Tronçon <git@el-tramo.be>2010-10-17 12:13:36 (GMT)
committerRemko Tronçon <git@el-tramo.be>2010-10-21 18:25:00 (GMT)
commit1b58ef2af54456004390a0888c3edf104e3baa99 (patch)
treedbe4ae29de1b765a88ea704dfaa1c03af4b196b3 /Swiften/Network/BoostConnection.cpp
parent07402c4e3451f2084a1c3ddc5bacfb38a66899a7 (diff)
downloadswift-1b58ef2af54456004390a0888c3edf104e3baa99.zip
swift-1b58ef2af54456004390a0888c3edf104e3baa99.tar.bz2
Added beginnings of outgoing file transfer to Swiften.
Diffstat (limited to 'Swiften/Network/BoostConnection.cpp')
-rw-r--r--Swiften/Network/BoostConnection.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/Swiften/Network/BoostConnection.cpp b/Swiften/Network/BoostConnection.cpp
index ccaae8a..8cd19f2 100644
--- a/Swiften/Network/BoostConnection.cpp
+++ b/Swiften/Network/BoostConnection.cpp
@@ -102,7 +102,7 @@ void BoostConnection::handleSocketRead(const boost::system::error_code& error, s
void BoostConnection::handleDataWritten(const boost::system::error_code& error) {
if (!error) {
- return;
+ MainEventLoop::postEvent(boost::ref(onDataWritten), shared_from_this());
}
if (error == boost::asio::error::eof) {
MainEventLoop::postEvent(boost::bind(boost::ref(onDisconnected), boost::optional<Error>()), shared_from_this());
@@ -112,4 +112,9 @@ void BoostConnection::handleDataWritten(const boost::system::error_code& error)
}
}
+HostAddressPort BoostConnection::getLocalAddress() const {
+ return HostAddressPort(socket_.local_endpoint());
+}
+
+
}