1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-08-03 22:35:43 +02:00

[341366] [dstore][shells] codepage IBM-1141 has faulty display of \ character

This commit is contained in:
David McKnight 2011-03-30 14:31:26 +00:00
parent 277ef77115
commit 5dbda26de8

View file

@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2006, 2010 IBM Corporation and others.
* Copyright (c) 2006, 2011 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
@ -22,6 +22,7 @@
* David McKnight (IBM) [302996] [dstore] null checks and performance issue with shell output
* David McKnight (IBM) [309338] [dstore] z/OS USS - invocation of 'env' shell command returns inconsistently organized output
* David McKnight (IBM) [312415] [dstore] shell service interprets < and > sequences - handle old client/new server case
* David McKnight (IBM) [341366] [dstore][shells] codepage IBM-1141 has faulty display of \ character
*******************************************************************************/
package org.eclipse.rse.internal.dstore.universal.miners.command;
@ -33,6 +34,7 @@ import java.util.List;
import java.util.StringTokenizer;
import org.eclipse.dstore.core.model.Handler;
import org.eclipse.dstore.internal.core.model.IDataStoreSystemProperties;
/**
* The OutputHandler class is used to listen to a particular output or error stream,
@ -74,7 +76,13 @@ public class OutputHandler extends Handler {
_encodings = new ArrayList();
String system = System.getProperty("os.name").toLowerCase(); //$NON-NLS-1$
// use special encoding first if it exists
String specialEncoding = System.getProperty(IDataStoreSystemProperties.DSTORE_STDIN_ENCODING);
if (specialEncoding != null) {
_encodings.add(specialEncoding);
}
if (system.startsWith("z")) { //$NON-NLS-1$
_encodings.add("IBM-1047"); //$NON-NLS-1$
/*
@ -82,11 +90,6 @@ public class OutputHandler extends Handler {
* _encodings.add("UTF8");
*/
} else {
String specialEncoding = System
.getProperty("dstore.stdin.encoding"); //$NON-NLS-1$
if (specialEncoding != null) {
_encodings.add(specialEncoding);
}
_encodings.add(System.getProperty("file.encoding")); //$NON-NLS-1$
}