forked from qt-creator/qt-creator
Maemo: Fix issue with cached device configuration.
External functions need to access the real device config, internal ones need the cached one during deployment. Task-number: QTCREATORBUG-4514
This commit is contained in:
@@ -395,10 +395,13 @@ void AbstractMaemoDeployStep::handleRemoteStderr(const QString &output)
|
||||
}
|
||||
|
||||
MaemoPortList AbstractMaemoDeployStep::freePorts() const
|
||||
{
|
||||
return freePorts(m_deviceConfig);
|
||||
}
|
||||
|
||||
MaemoPortList AbstractMaemoDeployStep::freePorts(const MaemoDeviceConfig::ConstPtr &devConf) const
|
||||
{
|
||||
const Qt4BuildConfiguration * const qt4bc = qt4BuildConfiguration();
|
||||
const MaemoDeviceConfig::ConstPtr &devConf
|
||||
= m_cachedDeviceConfig ? m_cachedDeviceConfig : m_deviceConfig;
|
||||
if (!devConf)
|
||||
return MaemoPortList();
|
||||
if (devConf->type() == MaemoDeviceConfig::Emulator && qt4bc) {
|
||||
|
||||
@@ -97,7 +97,9 @@ protected:
|
||||
|
||||
QString deployMountPoint() const;
|
||||
const Qt4BuildConfiguration *qt4BuildConfiguration() const;
|
||||
MaemoPortList freePorts(const QSharedPointer<const MaemoDeviceConfig> &devConfig) const;
|
||||
QSharedPointer<Utils::SshConnection> connection() const { return m_connection; }
|
||||
QSharedPointer<const MaemoDeviceConfig> cachedDeviceConfig() const { return m_cachedDeviceConfig; }
|
||||
|
||||
private slots:
|
||||
void start();
|
||||
|
||||
@@ -153,8 +153,8 @@ void AbstractMaemoDeployByMountStep::handleMountDebugOutput(const QString &outpu
|
||||
void AbstractMaemoDeployByMountStep::mount()
|
||||
{
|
||||
m_extendedState = Mounting;
|
||||
m_mounter->setupMounts(connection(), mountSpecifications(), freePorts(),
|
||||
qt4BuildConfiguration());
|
||||
m_mounter->setupMounts(connection(), mountSpecifications(),
|
||||
freePorts(cachedDeviceConfig()), qt4BuildConfiguration());
|
||||
}
|
||||
|
||||
QString AbstractMaemoDeployByMountStep::deployMountPoint() const
|
||||
|
||||
@@ -153,7 +153,7 @@ void MaemoDirectDeviceUploadStep::handleMkdirFinished(int exitStatus)
|
||||
raiseError(tr("Failed to upload file '%1'.").arg(nativePath));
|
||||
setFinished();
|
||||
} else if (fi.isDir()) {
|
||||
setDeployed(deviceConfig()->sshParameters().host, d);
|
||||
setDeployed(cachedDeviceConfig()->sshParameters().host, d);
|
||||
m_filesToUpload.removeFirst();
|
||||
uploadNextFile();
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user