Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDani Megert2012-06-20 07:45:23 +0000
committerDani Megert2012-06-20 07:45:23 +0000
commit636a9c73e7bb041f5bc0896be5fa1a4f9b70e1b7 (patch)
tree073413f6a122285b5ab6ca4fdf746793a706f441 /org.eclipse.debug.ui/ui
parent7ad6d6ab68424973b68d2624257ee18b4710f557 (diff)
downloadeclipse.platform.debug-636a9c73e7bb041f5bc0896be5fa1a4f9b70e1b7.tar.gz
eclipse.platform.debug-636a9c73e7bb041f5bc0896be5fa1a4f9b70e1b7.tar.xz
eclipse.platform.debug-636a9c73e7bb041f5bc0896be5fa1a4f9b70e1b7.zip
Fixed bug 382257: Console misinterpreting Unicode keyboard input
Diffstat (limited to 'org.eclipse.debug.ui/ui')
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/console/ProcessConsole.java10
1 files changed, 8 insertions, 2 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 03baa2aec..88cf70b0c 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
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2000, 2009 IBM Corporation and others.
+ * Copyright (c) 2000, 2012 IBM Corporation 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
@@ -83,6 +83,7 @@ import org.eclipse.ui.progress.UIJob;
import com.ibm.icu.text.MessageFormat;
+
/**
* A console for a system process with standard I/O streams.
*
@@ -671,13 +672,18 @@ public class ProcessConsole extends IOConsole implements IConsole, IDebugEventSe
* @see org.eclipse.core.runtime.jobs.Job#run(org.eclipse.core.runtime.IProgressMonitor)
*/
protected IStatus run(IProgressMonitor monitor) {
+ String encoding = getEncoding();
try {
byte[] b = new byte[1024];
int read = 0;
while (fInput != null && read >= 0) {
read = fInput.read(b);
if (read > 0) {
- String s = new String(b, 0, read);
+ String s;
+ if (encoding != null)
+ s = new String(b, 0, read, encoding);
+ else
+ s = new String(b, 0, read);
streamsProxy.write(s);
}
}

Back to the top