From b62c591f7a8781119e030c884d3e7c94df77de62 Mon Sep 17 00:00:00 2001 From: aclement Date: Thu, 27 Nov 2008 22:55:55 +0000 Subject: [PATCH] 249216:c22: escape path separators in source folder names --- .../org/aspectj/asm/internal/JDTLikeHandleProvider.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/asm/src/org/aspectj/asm/internal/JDTLikeHandleProvider.java b/asm/src/org/aspectj/asm/internal/JDTLikeHandleProvider.java index c20428d67..aa4900fb9 100644 --- a/asm/src/org/aspectj/asm/internal/JDTLikeHandleProvider.java +++ b/asm/src/org/aspectj/asm/internal/JDTLikeHandleProvider.java @@ -69,7 +69,12 @@ public class JDTLikeHandleProvider implements IElementHandleProvider { } else if (ipe.getKind() == IProgramElement.Kind.SOURCE_FOLDER) { StringBuffer sb = new StringBuffer(); sb.append(createHandleIdentifier(ipe.getParent())).append("/"); - sb.append(ipe.getName()); + // pr249216 - escape any embedded slashes + String folder = ipe.getName(); + if (folder.indexOf("/") != -1) { + folder = folder.replace("/", "\\/"); + } + sb.append(folder); String handle = sb.toString(); ipe.setHandleIdentifier(handle); return handle; -- 2.39.5