From 252ea4ba20e909ec5530878124fba23003ce8d46 Mon Sep 17 00:00:00 2001 From: Aleix Pol Date: Fri, 3 Jun 2016 16:38:04 +0200 Subject: [PATCH] Fix file transfers --- core/backends/lan/downloadjob.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/core/backends/lan/downloadjob.cpp b/core/backends/lan/downloadjob.cpp index 6d17b8dc9..1cbdb6a2c 100644 --- a/core/backends/lan/downloadjob.cpp +++ b/core/backends/lan/downloadjob.cpp @@ -58,9 +58,8 @@ void DownloadJob::start() connect(mSocket.data(), SIGNAL(error(QAbstractSocket::SocketError)), this, SLOT(done())); //connect(mSocket.data(), &QAbstractSocket::connected, [=](){ qDebug() << "Connected"; }); - // Cannot use read only, might be due to ssl handshake, getting QIODevice::ReadOnly error and no connection - mSocket->connectToHostEncrypted(mAddress.toString(), mPort, QIODevice::ReadWrite); - mSocket->waitForEncrypted(); + mSocket->connectToHost(mAddress.toString(), mPort); + mSocket->waitForConnected(); // mSocket->connectToHost(mAddress, mPort, QIODevice::ReadOnly); // mSocket->waitForConnected();