From 8113f6353226c547cbf9cd78bdcb5aea33649471 Mon Sep 17 00:00:00 2001 From: Mikhail Khodjaiants Date: Fri, 21 Mar 2014 13:27:11 -0400 Subject: [PATCH] Bug 426834 - Failure to install breakpoint in GDB when spaces are in the workspace path Change-Id: I9487275bd5c8c5a5cacbadd884c2fa38e49dd6dd Reviewed-on: https://git.eclipse.org/r/23732 Reviewed-by: Marc Khouzam IP-Clean: Mikhail Khodjaiants Tested-by: Mikhail Khodjaiants --- .../command/commands/MIBreakInsert.java | 23 +++---------------- 1 file changed, 3 insertions(+), 20 deletions(-) diff --git a/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/mi/service/command/commands/MIBreakInsert.java b/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/mi/service/command/commands/MIBreakInsert.java index f653ead1443..0ab83a75855 100644 --- a/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/mi/service/command/commands/MIBreakInsert.java +++ b/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/mi/service/command/commands/MIBreakInsert.java @@ -172,30 +172,13 @@ public class MIBreakInsert extends MICommand if (opts.length > 0) { setOptions(opts); } - setParameters(new Adjustable[]{ new PathAdjustable(location)}); + // Code that replaced double backslashes with single backslashes is removed. + // See https://bugs.eclipse.org/bugs/show_bug.cgi?id=426834 for details. + setParameters(new Adjustable[]{ new MIStandardParameterAdjustable(location)}); } @Override public MIBreakInsertInfo getResult(MIOutput output) { return new MIBreakInsertInfo(output); } - - /** - * This adjustable makes sure that the path parameter will not get the - * backslashes substituted with double backslashes. - */ - private class PathAdjustable - extends - org.eclipse.cdt.dsf.mi.service.command.commands.MICommand.MIStandardParameterAdjustable { - - public PathAdjustable(String path) { - super(path); - } - - @Override - public String getAdjustedValue() { - String adjustedValue = super.getAdjustedValue(); - return adjustedValue.replace("\\\\", "\\"); //$NON-NLS-1$//$NON-NLS-2$ - } - } }