From 99f3926d0546032814077cf0d0a684ed80e7bb08 Mon Sep 17 00:00:00 2001 From: Joakim Erdfelt Date: Tue, 16 Apr 2019 14:49:03 -0500 Subject: [PATCH] Issue #3555 - Applying changes from review Signed-off-by: Joakim Erdfelt --- .../org/eclipse/jetty/server/handler/DefaultHandler.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/jetty-server/src/main/java/org/eclipse/jetty/server/handler/DefaultHandler.java b/jetty-server/src/main/java/org/eclipse/jetty/server/handler/DefaultHandler.java index ebfabc7eeba..a2c8b171f68 100644 --- a/jetty-server/src/main/java/org/eclipse/jetty/server/handler/DefaultHandler.java +++ b/jetty-server/src/main/java/org/eclipse/jetty/server/handler/DefaultHandler.java @@ -118,14 +118,14 @@ public class DefaultHandler extends AbstractHandler } response.setStatus(HttpServletResponse.SC_NOT_FOUND); - response.setContentType(MimeTypes.Type.TEXT_HTML.toString()); + response.setContentType(MimeTypes.Type.TEXT_HTML_UTF_8.toString()); try (ByteArrayOutputStream outputStream = new ByteArrayOutputStream(); OutputStreamWriter writer = new OutputStreamWriter(outputStream, UTF_8)) { writer.append("\n"); writer.append("\n\n"); - writer.append("Error 404 - Not Found"); + writer.append("Error 404 - Not Found\n"); writer.append("\n"); writer.append("\n"); writer.append("\n\n"); @@ -141,7 +141,7 @@ public class DefaultHandler extends AbstractHandler writer.append("Display Name"); writer.append("State"); writer.append("LifeCycle"); - writer.append(""); + writer.append("\n"); for (int i=0;handlers!=null && i
\n"); writer.append("\"icon\" "); writer.append("Powered by Eclipse Jetty:// Server
\n"); - writer.append("\n\n\n"); + writer.append("\n\n"); writer.flush(); byte content[] = outputStream.toByteArray(); response.setContentLength(content.length);