forked from qt-creator/qt-creator
SSH: Shorten the path name of the control socket
The maximum path length for a UNIX domain socket is much lower than for other file types. Fixes: QTCREATORBUG-21748 Change-Id: I5e27169f356d7a2960a817e308a1f5d4858b6f7d Reviewed-by: James McDonnell <jmcdonnell@blackberry.com>
This commit is contained in:
@@ -108,7 +108,7 @@ struct SshConnection::SshConnectionPrivate
|
||||
QString socketFilePath() const
|
||||
{
|
||||
QTC_ASSERT(masterSocketDir, return QString());
|
||||
return masterSocketDir->path() + "/control_socket";
|
||||
return masterSocketDir->path() + "/cs";
|
||||
}
|
||||
|
||||
QStringList connectionOptions() const
|
||||
@@ -352,7 +352,7 @@ void SshConnection::doConnectToHost()
|
||||
if (!d->sharingEnabled)
|
||||
emitConnected();
|
||||
QTC_ASSERT(TemporaryDirectory::masterTemporaryDirectory(), return);
|
||||
d->masterSocketDir.reset(new TemporaryDirectory("qtc-ssh-XXXXXX"));
|
||||
d->masterSocketDir.reset(new TemporaryDirectory("ssh-XXXXXX"));
|
||||
if (!d->masterSocketDir->isValid()) {
|
||||
emitError(tr("Cannot establish SSH connection: Failed to create temporary "
|
||||
"directory for control socket: %1")
|
||||
|
||||
Reference in New Issue
Block a user