summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swiften/FileTransfer/OutgoingSIFileTransfer.cpp')
-rw-r--r--Swiften/FileTransfer/OutgoingSIFileTransfer.cpp22
1 files changed, 15 insertions, 7 deletions
diff --git a/Swiften/FileTransfer/OutgoingSIFileTransfer.cpp b/Swiften/FileTransfer/OutgoingSIFileTransfer.cpp
index fc0a551..1c60469 100644
--- a/Swiften/FileTransfer/OutgoingSIFileTransfer.cpp
+++ b/Swiften/FileTransfer/OutgoingSIFileTransfer.cpp
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2010 Remko Tronçon
+ * Copyright (c) 2010-2013 Remko Tronçon
* Licensed under the GNU General Public License v3.
* See Documentation/Licenses/GPLv3.txt for more information.
*/
@@ -16,10 +16,11 @@
namespace Swift {
-OutgoingSIFileTransfer::OutgoingSIFileTransfer(const std::string& id, const JID& from, const JID& to, const std::string& name, int size, const std::string& description, boost::shared_ptr<ReadBytestream> bytestream, IQRouter* iqRouter, SOCKS5BytestreamServer* socksServer) : id(id), from(from), to(to), name(name), size(size), description(description), bytestream(bytestream), iqRouter(iqRouter), socksServer(socksServer) {
+OutgoingSIFileTransfer::OutgoingSIFileTransfer(const std::string& id, const JID& from, const JID& to, const std::string& name, unsigned long long size, const std::string& description, boost::shared_ptr<ReadBytestream> bytestream, IQRouter* iqRouter, SOCKS5BytestreamServer* socksServer) : id(id), from(from), to(to), name(name), size(size), description(description), bytestream(bytestream), iqRouter(iqRouter), socksServer(socksServer) {
}
void OutgoingSIFileTransfer::start() {
+ /*
StreamInitiation::ref streamInitiation(new StreamInitiation());
streamInitiation->setID(id);
streamInitiation->setFileInfo(StreamInitiationFileInfo(name, description, size));
@@ -28,12 +29,14 @@ void OutgoingSIFileTransfer::start() {
StreamInitiationRequest::ref request = StreamInitiationRequest::create(to, streamInitiation, iqRouter);
request->onResponse.connect(boost::bind(&OutgoingSIFileTransfer::handleStreamInitiationRequestResponse, this, _1, _2));
request->send();
+ */
}
void OutgoingSIFileTransfer::stop() {
}
-void OutgoingSIFileTransfer::handleStreamInitiationRequestResponse(StreamInitiation::ref response, ErrorPayload::ref error) {
+void OutgoingSIFileTransfer::handleStreamInitiationRequestResponse(StreamInitiation::ref, ErrorPayload::ref) {
+ /*
if (error) {
finish(FileTransferError());
}
@@ -54,26 +57,31 @@ void OutgoingSIFileTransfer::handleStreamInitiationRequestResponse(StreamInitiat
ibbSession->start();
}
}
+ */
}
-void OutgoingSIFileTransfer::handleBytestreamsRequestResponse(Bytestreams::ref, ErrorPayload::ref error) {
+void OutgoingSIFileTransfer::handleBytestreamsRequestResponse(Bytestreams::ref, ErrorPayload::ref) {
+ /*
if (error) {
finish(FileTransferError());
}
+ */
//socksServer->onTransferFinished.connect();
}
-void OutgoingSIFileTransfer::finish(boost::optional<FileTransferError> error) {
+void OutgoingSIFileTransfer::finish(boost::optional<FileTransferError>) {
+ /*
if (ibbSession) {
ibbSession->onFinished.disconnect(boost::bind(&OutgoingSIFileTransfer::handleIBBSessionFinished, this, _1));
ibbSession.reset();
}
socksServer->removeReadBytestream(id, from, to);
onFinished(error);
+ */
}
-void OutgoingSIFileTransfer::handleIBBSessionFinished(boost::optional<FileTransferError> error) {
- finish(error);
+void OutgoingSIFileTransfer::handleIBBSessionFinished(boost::optional<FileTransferError>) {
+ //finish(error);
}
}