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 513367 | Differences between
and this patch

Collapse All | Expand All

(-)a/org.eclipse.ui.console/src/org/eclipse/ui/console/IOConsoleOutputStream.java (+6 lines)
Lines 199-204 Link Here
199
     */
199
     */
200
    @Override
200
    @Override
201
	public synchronized void write(byte[] b, int off, int len) throws IOException {
201
	public synchronized void write(byte[] b, int off, int len) throws IOException {
202
		if (closed) {
203
			throw new IOException("Output Stream is closed"); //$NON-NLS-1$
204
		}
202
		StringBuilder builder = new StringBuilder();
205
		StringBuilder builder = new StringBuilder();
203
		this.decoder.decode(builder, b, off, len);
206
		this.decoder.decode(builder, b, off, len);
204
		encodedWrite(builder.toString());
207
		encodedWrite(builder.toString());
Lines 323-328 Link Here
323
	 * @since 3.7
326
	 * @since 3.7
324
	 */
327
	 */
325
	public synchronized void setCharset(Charset charset) throws IOException {
328
	public synchronized void setCharset(Charset charset) throws IOException {
329
		if (closed) {
330
			throw new IOException("Output Stream is closed"); //$NON-NLS-1$
331
		}
326
		StringBuilder builder = new StringBuilder();
332
		StringBuilder builder = new StringBuilder();
327
		this.decoder.finish(builder);
333
		this.decoder.finish(builder);
328
		if (builder.length() > 0) {
334
		if (builder.length() > 0) {

Return to bug 513367