diff options
author | Remko Tronçon <git@el-tramo.be> | 2010-10-17 12:13:36 (GMT) |
---|---|---|
committer | Remko Tronçon <git@el-tramo.be> | 2010-10-21 18:25:00 (GMT) |
commit | 1b58ef2af54456004390a0888c3edf104e3baa99 (patch) | |
tree | dbe4ae29de1b765a88ea704dfaa1c03af4b196b3 /Swiften/Network/BoostConnection.cpp | |
parent | 07402c4e3451f2084a1c3ddc5bacfb38a66899a7 (diff) | |
download | swift-contrib-1b58ef2af54456004390a0888c3edf104e3baa99.zip swift-contrib-1b58ef2af54456004390a0888c3edf104e3baa99.tar.bz2 |
Added beginnings of outgoing file transfer to Swiften.
Diffstat (limited to 'Swiften/Network/BoostConnection.cpp')
-rw-r--r-- | Swiften/Network/BoostConnection.cpp | 7 |
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()); +} + + } |