Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMikhail Khodjaiants2010-02-04 12:21:43 +0000
committerMikhail Khodjaiants2010-02-04 12:21:43 +0000
commitd81756f82e3d87dc07354cd953a67a55e2fd2bc1 (patch)
tree1417faaef2f28df2bceb2a436606cdb949f31af9 /debug/org.eclipse.cdt.debug.mi.core
parent687fffa7935ec01e65822b0e9ca109a3d85ad385 (diff)
downloadorg.eclipse.cdt-d81756f82e3d87dc07354cd953a67a55e2fd2bc1.tar.gz
org.eclipse.cdt-d81756f82e3d87dc07354cd953a67a55e2fd2bc1.tar.xz
org.eclipse.cdt-d81756f82e3d87dc07354cd953a67a55e2fd2bc1.zip
Bug 301706: Mac OS: Debugger can not handle file paths with spaces.
Diffstat (limited to 'debug/org.eclipse.cdt.debug.mi.core')
-rw-r--r--debug/org.eclipse.cdt.debug.mi.core/mi/org/eclipse/cdt/debug/mi/core/command/factories/macos/MacOSMIEnvironmentCD.java9
1 files changed, 6 insertions, 3 deletions
diff --git a/debug/org.eclipse.cdt.debug.mi.core/mi/org/eclipse/cdt/debug/mi/core/command/factories/macos/MacOSMIEnvironmentCD.java b/debug/org.eclipse.cdt.debug.mi.core/mi/org/eclipse/cdt/debug/mi/core/command/factories/macos/MacOSMIEnvironmentCD.java
index b9905acb40b..36c1ff61a3e 100644
--- a/debug/org.eclipse.cdt.debug.mi.core/mi/org/eclipse/cdt/debug/mi/core/command/factories/macos/MacOSMIEnvironmentCD.java
+++ b/debug/org.eclipse.cdt.debug.mi.core/mi/org/eclipse/cdt/debug/mi/core/command/factories/macos/MacOSMIEnvironmentCD.java
@@ -1,5 +1,5 @@
/**********************************************************************
- * Copyright (c) 2006 Nokia and others.
+ * Copyright (c) 2006, 2010 Nokia and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
@@ -7,6 +7,7 @@
*
* Contributors:
* Nokia - Initial API and implementation
+ * Marc-Andre Laperle - fix for bug 263689 (spaces in directory)
***********************************************************************/
package org.eclipse.cdt.debug.mi.core.command.factories.macos;
@@ -16,13 +17,15 @@ public class MacOSMIEnvironmentCD extends MIEnvironmentCD {
public MacOSMIEnvironmentCD(String miVersion, String path) {
super(miVersion, path);
- this.setOperation("cd");//$NON-NLS-1$
+ this.setOperation("-environment-cd");//$NON-NLS-1$
}
protected String parametersToString() {
String[] parameters = getParameters();
if (parameters != null && parameters.length == 1) {
- return '"' + parameters[0] + '"';
+ // To handle spaces in the path, the command string has this format:
+ // -environment-cd "\"/path with spaces\""
+ return "\"\\\"" + parameters[0] + "\\\"\""; //$NON-NLS-1$ //$NON-NLS-2$
}
return super.parametersToString();
}

Back to the top