Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Pazderski2020-02-22 20:23:28 +0000
committerPaul Pazderski2020-05-01 23:17:19 +0000
commit79c7833392ac1e85adf0f48e5808998c6f3a1caf (patch)
tree17817364c3e69c10f2424c6eab4237e024b016f4 /org.eclipse.debug.ui/ui/org
parent4296b4127e2e3b8549f5733c4c7d8f2f24a4b891 (diff)
downloadeclipse.platform.debug-79c7833392ac1e85adf0f48e5808998c6f3a1caf.tar.gz
eclipse.platform.debug-79c7833392ac1e85adf0f48e5808998c6f3a1caf.tar.xz
eclipse.platform.debug-79c7833392ac1e85adf0f48e5808998c6f3a1caf.zip
Bug 333239 - [console] Console redirection treats file name as regularI20200505-1800I20200504-1800I20200503-1800I20200502-1800
expression Change-Id: I8b475d001a6e0a626540d9aa93285fa918d4b21e Signed-off-by: Paul Pazderski <paul-eclipse@ppazderski.de>
Diffstat (limited to 'org.eclipse.debug.ui/ui/org')
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ProcessConsole.java15
1 files changed, 3 insertions, 12 deletions
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ProcessConsole.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ProcessConsole.java
index be44bdc16..a759e5dbc 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ProcessConsole.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ProcessConsole.java
@@ -34,6 +34,7 @@ import java.time.temporal.ChronoUnit;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
+import java.util.regex.Pattern;
import org.eclipse.core.resources.IFile;
import org.eclipse.core.resources.IStorage;
@@ -884,22 +885,12 @@ public class ProcessConsole extends IOConsole implements IConsole, IDebugEventSe
String fFilePath;
public ConsoleLogFilePatternMatcher(String filePath) {
- fFilePath = escape(filePath);
- }
-
- private String escape(String path) {
- StringBuilder buffer = new StringBuilder(path);
- int index = buffer.indexOf("\\"); //$NON-NLS-1$
- while (index >= 0) {
- buffer.insert(index, '\\');
- index = buffer.indexOf("\\", index+2); //$NON-NLS-1$
- }
- return buffer.toString();
+ fFilePath = filePath;
}
@Override
public String getPattern() {
- return fFilePath;
+ return Pattern.quote(fFilePath);
}
@Override

Back to the top