aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/debugger/debuggerruncontrol.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/debugger/debuggerruncontrol.cpp')
-rw-r--r--src/plugins/debugger/debuggerruncontrol.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/plugins/debugger/debuggerruncontrol.cpp b/src/plugins/debugger/debuggerruncontrol.cpp
index 5bb4845073d..19b40113383 100644
--- a/src/plugins/debugger/debuggerruncontrol.cpp
+++ b/src/plugins/debugger/debuggerruncontrol.cpp
@@ -61,6 +61,7 @@
#include <utils/temporarydirectory.h>
#include <utils/temporaryfile.h>
#include <utils/url.h>
+#include <utils/winutils.h>
#include <coreplugin/icontext.h>
#include <coreplugin/icore.h>
@@ -565,6 +566,17 @@ void DebuggerRunTool::start()
if (!fixupParameters())
return;
+ if (m_runParameters.cppEngineType == CdbEngineType
+ && Utils::is64BitWindowsBinary(m_runParameters.inferior.executable)
+ && !Utils::is64BitWindowsBinary(m_runParameters.debugger.executable)) {
+ reportFailure(
+ DebuggerPlugin::tr(
+ "%1 is a 64 bit executable which can not be debugged by a 32 bit Debugger.\n"
+ "Please select a 64 bit Debugger in the kit settings for this kit.")
+ .arg(m_runParameters.inferior.executable));
+ return;
+ }
+
Utils::globalMacroExpander()->registerFileVariables(
"DebuggedExecutable", tr("Debugged executable"),
[this] { return m_runParameters.inferior.executable; }