telepathy-qt: OutgoingFileTransferChannel: Fixed transfer with sequential devices.
Alexandr Akulich
kaffeine at kemper.freedesktop.org
Sat Apr 23 08:33:21 UTC 2016
Module: telepathy-qt
Branch: master
Commit: 6c621ab2de7928d7341ee6fa696192445d32d8ec
URL: http://cgit.freedesktop.org/telepathy/telepathy-qt/commit/?id=6c621ab2de7928d7341ee6fa696192445d32d8ec
Author: Alexandr Akulich <akulichalexander at gmail.com>
Date: Tue Feb 16 20:05:04 2016 +0500
OutgoingFileTransferChannel: Fixed transfer with sequential devices.
---
TelepathyQt/outgoing-file-transfer-channel.cpp | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/TelepathyQt/outgoing-file-transfer-channel.cpp b/TelepathyQt/outgoing-file-transfer-channel.cpp
index 5e850df..6f12ec8 100644
--- a/TelepathyQt/outgoing-file-transfer-channel.cpp
+++ b/TelepathyQt/outgoing-file-transfer-channel.cpp
@@ -238,6 +238,8 @@ void OutgoingFileTransferChannel::connectToHost()
return;
}
+ mPriv->pos = initialOffset();
+
mPriv->socket = new QTcpSocket(this);
connect(mPriv->socket, SIGNAL(connected()),
@@ -263,10 +265,8 @@ void OutgoingFileTransferChannel::onSocketConnected()
SLOT(doTransfer()));
// for non sequential devices, let's seek to the initialOffset
- if (!mPriv->input->isSequential()) {
- if (mPriv->input->seek(initialOffset())) {
- mPriv->pos = initialOffset();
- }
+ if (mPriv->weOpenedDevice && !mPriv->input->isSequential()) {
+ mPriv->input->seek(initialOffset());
}
debug() << "Starting transfer...";
More information about the telepathy-commits
mailing list