forked from qt-creator/qt-creator
RemoteLinux: Use an SshProcess for rsync
Otherwise, if connection sharing is disabled and public key authentication fails, the askpass tool is not invoked. Change-Id: Iea8316675b8f270c924f822f340f6282b21450d5 Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -26,7 +26,7 @@
|
||||
#include "sftpsession.h"
|
||||
|
||||
#include "sshlogging_p.h"
|
||||
#include "sshprocess_p.h"
|
||||
#include "sshprocess.h"
|
||||
#include "sshsettings.h"
|
||||
|
||||
#include <utils/fileutils.h>
|
||||
|
@@ -25,7 +25,7 @@
|
||||
|
||||
#include "sftptransfer.h"
|
||||
|
||||
#include "sshprocess_p.h"
|
||||
#include "sshprocess.h"
|
||||
#include "sshsettings.h"
|
||||
|
||||
#include <QDir>
|
||||
@@ -43,7 +43,7 @@ namespace QSsh {
|
||||
|
||||
struct SftpTransfer::SftpTransferPrivate
|
||||
{
|
||||
Internal::SshProcess sftpProc;
|
||||
SshProcess sftpProc;
|
||||
FilesToTransfer files;
|
||||
Internal::FileTransferType transferType;
|
||||
FileTransferErrorHandling errorHandlingMode;
|
||||
|
@@ -26,7 +26,7 @@ HEADERS = \
|
||||
sshconnectionmanager.h \
|
||||
sshkeycreationdialog.h \
|
||||
sshlogging_p.h \
|
||||
sshprocess_p.h \
|
||||
sshprocess.h \
|
||||
sshremoteprocess.h \
|
||||
sshremoteprocessrunner.h \
|
||||
sshsettings.h \
|
||||
|
@@ -32,7 +32,7 @@ Project {
|
||||
"sshlogging.cpp",
|
||||
"sshlogging_p.h",
|
||||
"sshprocess.cpp",
|
||||
"sshprocess_p.h",
|
||||
"sshprocess.h",
|
||||
"sshremoteprocess.cpp",
|
||||
"sshremoteprocess.h",
|
||||
"sshremoteprocessrunner.cpp",
|
||||
|
@@ -28,7 +28,7 @@
|
||||
#include "sftpsession.h"
|
||||
#include "sftptransfer.h"
|
||||
#include "sshlogging_p.h"
|
||||
#include "sshprocess_p.h"
|
||||
#include "sshprocess.h"
|
||||
#include "sshremoteprocess.h"
|
||||
#include "sshsettings.h"
|
||||
|
||||
|
@@ -23,7 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#include "sshprocess_p.h"
|
||||
#include "sshprocess.h"
|
||||
|
||||
#include "sshsettings.h"
|
||||
|
||||
@@ -35,7 +35,6 @@
|
||||
#endif
|
||||
|
||||
namespace QSsh {
|
||||
namespace Internal {
|
||||
|
||||
SshProcess::SshProcess()
|
||||
{
|
||||
@@ -70,5 +69,4 @@ void SshProcess::setupChildProcess()
|
||||
#endif
|
||||
}
|
||||
|
||||
} // namespace Internal
|
||||
} // namespace QSsh
|
||||
|
@@ -25,12 +25,13 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "ssh_global.h"
|
||||
|
||||
#include <QProcess>
|
||||
|
||||
namespace QSsh {
|
||||
namespace Internal {
|
||||
|
||||
class SshProcess : public QProcess
|
||||
class QSSH_EXPORT SshProcess : public QProcess
|
||||
{
|
||||
public:
|
||||
SshProcess();
|
||||
@@ -40,5 +41,4 @@ private:
|
||||
void setupChildProcess() override;
|
||||
};
|
||||
|
||||
} // namespace Internal
|
||||
} // namespace QSsh
|
@@ -26,7 +26,7 @@
|
||||
#pragma once
|
||||
|
||||
#include "ssh_global.h"
|
||||
#include "sshprocess_p.h"
|
||||
#include "sshprocess.h"
|
||||
|
||||
#include <QStringList>
|
||||
|
||||
@@ -37,7 +37,7 @@ QT_END_NAMESPACE
|
||||
namespace QSsh {
|
||||
class SshConnection;
|
||||
|
||||
class QSSH_EXPORT SshRemoteProcess : public Internal::SshProcess
|
||||
class QSSH_EXPORT SshRemoteProcess : public SshProcess
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
|
@@ -55,7 +55,7 @@ public:
|
||||
SshRemoteProcessPtr process;
|
||||
DeviceUsedPortsGatherer portsGatherer;
|
||||
SftpSessionPtr sftpSession;
|
||||
QProcess rsyncProcess;
|
||||
SshProcess rsyncProcess;
|
||||
State state = Inactive;
|
||||
bool sftpWorks = false;
|
||||
};
|
||||
|
@@ -69,7 +69,7 @@ private:
|
||||
|
||||
mutable QList<DeployableFile> m_deployableFiles;
|
||||
bool m_ignoreMissingFiles = false;
|
||||
QProcess m_rsync;
|
||||
SshProcess m_rsync;
|
||||
SshRemoteProcessPtr m_mkdir;
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user