aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/http/BaseServlet.java
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2015-07-12 11:56:33 +1200
committerAnton Tananaev <anton.tananaev@gmail.com>2015-07-12 11:56:33 +1200
commit2badcd16f7ae0ce46f7c0cd241c635493d7e6508 (patch)
tree075b13ee9586bb99b2a51d1e169d65d4d14bbb54 /src/org/traccar/http/BaseServlet.java
parentecbbcc01f89acc85d02cfbd1201253411a4604e4 (diff)
downloadtrackermap-server-2badcd16f7ae0ce46f7c0cd241c635493d7e6508.tar.gz
trackermap-server-2badcd16f7ae0ce46f7c0cd241c635493d7e6508.tar.bz2
trackermap-server-2badcd16f7ae0ce46f7c0cd241c635493d7e6508.zip
Set correct JSON content type (fix #1298)
Diffstat (limited to 'src/org/traccar/http/BaseServlet.java')
-rw-r--r--src/org/traccar/http/BaseServlet.java2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/org/traccar/http/BaseServlet.java b/src/org/traccar/http/BaseServlet.java
index 89eefc11c..394e4d317 100644
--- a/src/org/traccar/http/BaseServlet.java
+++ b/src/org/traccar/http/BaseServlet.java
@@ -38,6 +38,8 @@ public abstract class BaseServlet extends HttpServlet {
command = "";
}
try {
+ resp.setContentType("application/json");
+ resp.setCharacterEncoding("UTF-8");
if (!handle(command, req, resp)) {
resp.sendError(HttpServletResponse.SC_BAD_REQUEST);
}