Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
View | Details | Raw Unified | Return to bug 202095 | Differences between
and this patch

Collapse All | Expand All

(-)src/org/eclipse/core/internal/resources/PathVariableManager.java (-3 / +4 lines)
Lines 14-19 Link Here
14
import java.util.*;
14
import java.util.*;
15
import org.eclipse.core.filesystem.URIUtil;
15
import org.eclipse.core.filesystem.URIUtil;
16
import org.eclipse.core.internal.events.PathVariableChangeEvent;
16
import org.eclipse.core.internal.events.PathVariableChangeEvent;
17
import org.eclipse.core.internal.utils.FileUtil;
17
import org.eclipse.core.internal.utils.Messages;
18
import org.eclipse.core.internal.utils.Messages;
18
import org.eclipse.core.resources.*;
19
import org.eclipse.core.resources.*;
19
import org.eclipse.core.runtime.*;
20
import org.eclipse.core.runtime.*;
Lines 184-192 Link Here
184
	 */
185
	 */
185
	public void setValue(String varName, IPath newValue) throws CoreException {
186
	public void setValue(String varName, IPath newValue) throws CoreException {
186
		checkIsValidName(varName);
187
		checkIsValidName(varName);
187
		//if the location doesn't have a device, see if the OS will assign one
188
		//convert path value to canonical form
188
		if (newValue != null && newValue.isAbsolute() && newValue.getDevice() == null)
189
		if (newValue != null && newValue.isAbsolute())
189
			newValue = new Path(newValue.toFile().getAbsolutePath());
190
			newValue = FileUtil.canonicalPath(newValue);
190
		checkIsValidValue(newValue);
191
		checkIsValidValue(newValue);
191
		int eventType;
192
		int eventType;
192
		// read previous value and set new value atomically in order to generate the right event		
193
		// read previous value and set new value atomically in order to generate the right event		

Return to bug 202095