This commit is contained in:
Fuzzlemann 2017-07-29 23:25:28 +02:00
commit 9879faa8a8

View File

@ -94,7 +94,7 @@ public class WebServer {
Response response = getResponse(target, user); Response response = getResponse(target, user);
String content = response.getContent(); String content = response.getContent();
exchange.sendResponseHeaders(200, 0); exchange.sendResponseHeaders(response.getCode(), 0);
try (BufferedOutputStream out = new BufferedOutputStream(exchange.getResponseBody()); try (BufferedOutputStream out = new BufferedOutputStream(exchange.getResponseBody());
ByteArrayInputStream bis = new ByteArrayInputStream(content.getBytes())) { ByteArrayInputStream bis = new ByteArrayInputStream(content.getBytes())) {