From e4aed35b52b3147454de80a8793c912d617dc68f Mon Sep 17 00:00:00 2001 From: Marc Khouzam Date: Wed, 26 Oct 2011 15:24:49 -0400 Subject: [PATCH] Bug 362105: Cancelling a launch during the prompt for the corefile gives an error --- .../cdt/dsf/gdb/launching/FinalLaunchSequence.java | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/gdb/launching/FinalLaunchSequence.java b/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/gdb/launching/FinalLaunchSequence.java index 54b74473a74..9805cecc1bc 100644 --- a/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/gdb/launching/FinalLaunchSequence.java +++ b/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/gdb/launching/FinalLaunchSequence.java @@ -414,7 +414,17 @@ public class FinalLaunchSequence extends ReflectionSequence { // Even if binary is null, we must call this to do all the other steps // necessary to create a process. It is possible that the binary is not needed fProcService.debugNewProcess(fCommandControl.getContext(), binary, fAttributes, - new DataRequestMonitor(getExecutor(), rm)); + new DataRequestMonitor(getExecutor(), rm) { + @Override + protected void handleCancel() { + // If this step is cancelled, cancel the current sequence. + // This is to allow the user to press the cancel button + // when prompted for a post-mortem file. + // Bug 362105 + rm.cancel(); + rm.done(); + } + }); } else { rm.done(); }