Use HostOsInfo::withExecutableSuffix instead of if/else

Let's use our Utils.

Change-Id: I8cfbce55d2b41e42e86d050433df2cfd20cebe1b
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
Alessandro Portale
2019-11-14 16:07:55 +01:00
parent b7395e97f3
commit 9c43466485
4 changed files with 6 additions and 23 deletions

View File

@@ -589,10 +589,7 @@ void AndroidRunnerWorker::handleJdbWaiting()
m_afterFinishAdbCommands.push_back(removeForward.join(' '));
auto jdbPath = AndroidConfigurations::currentConfig().openJDKLocation().pathAppended("bin");
if (Utils::HostOsInfo::isWindowsHost())
jdbPath = jdbPath.pathAppended("jdb.exe");
else
jdbPath = jdbPath.pathAppended("jdb");
jdbPath = jdbPath.pathAppended(Utils::HostOsInfo::withExecutableSuffix("jdb"));
QStringList jdbArgs("-connect");
jdbArgs << QString("com.sun.jdi.SocketAttach:hostname=localhost,port=%1")