forked from qt-creator/qt-creator
Debugger: Restrict the file name pattern of potential lldb executables
We now try executables such as lldb-7 or lldb-1024, but not e.g. lldb- vscode, which used to time out the autodetection code. Change-Id: Iac3b6c4d55d34ee98073f99c8e8341011845ca92 Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -702,7 +702,7 @@ void DebuggerItemManagerPrivate::autoDetectCdbDebuggers()
|
||||
void DebuggerItemManagerPrivate::autoDetectGdbOrLldbDebuggers()
|
||||
{
|
||||
const QStringList filters = {"gdb-i686-pc-mingw32", "gdb-i686-pc-mingw32.exe", "gdb",
|
||||
"gdb.exe", "lldb", "lldb.exe", "lldb-*"};
|
||||
"gdb.exe", "lldb", "lldb.exe", "lldb-[1-9]*"};
|
||||
|
||||
// DebuggerItem result;
|
||||
// result.setAutoDetected(true);
|
||||
@@ -748,14 +748,8 @@ void DebuggerItemManagerPrivate::autoDetectGdbOrLldbDebuggers()
|
||||
dir.setFilter(QDir::Files | QDir::Executable);
|
||||
foreach (const Utils::FileName &base, path) {
|
||||
dir.setPath(base.toFileInfo().absoluteFilePath());
|
||||
foreach (const QString &entry, dir.entryList()) {
|
||||
if (entry.startsWith("lldb-platform-")
|
||||
|| entry.startsWith("lldb-gdbserver-")
|
||||
|| entry.startsWith("lldb-mi-")) {
|
||||
continue;
|
||||
}
|
||||
foreach (const QString &entry, dir.entryList())
|
||||
suspects.append(FileName::fromString(dir.absoluteFilePath(entry)));
|
||||
}
|
||||
}
|
||||
|
||||
foreach (const FileName &command, suspects) {
|
||||
|
||||
Reference in New Issue
Block a user