From ea36b7b153335a512397a924bb71de6815c3760f Mon Sep 17 00:00:00 2001
From: zzz <zzz@mail.i2p>
Date: Tue, 15 Dec 2009 01:46:10 +0000
Subject: [PATCH] susidns UTF-8 fixes

---
 apps/susidns/src/bundle-messages.sh    | 2 +-
 apps/susidns/src/jsp/addressbook.jsp   | 2 ++
 apps/susidns/src/jsp/config.jsp        | 2 ++
 apps/susidns/src/jsp/index.jsp         | 2 ++
 apps/susidns/src/jsp/subscriptions.jsp | 2 ++
 5 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/apps/susidns/src/bundle-messages.sh b/apps/susidns/src/bundle-messages.sh
index e21706e880..e46eccd73f 100755
--- a/apps/susidns/src/bundle-messages.sh
+++ b/apps/susidns/src/bundle-messages.sh
@@ -75,7 +75,7 @@ do
 	echo "Generating ${CLASS}_$LG ResourceBundle..."
 
 	# convert to class files in build/obj
-	msgfmt --java -r $CLASS -l $LG -d WEB-INF/classes $i
+	msgfmt --java --statistics -r $CLASS -l $LG -d WEB-INF/classes $i
 	if [ $? -ne 0 ]
 	then
 		echo 'Warning - msgfmt failed, not updating translations'
diff --git a/apps/susidns/src/jsp/addressbook.jsp b/apps/susidns/src/jsp/addressbook.jsp
index 2bcf298ed2..d9ff34695f 100644
--- a/apps/susidns/src/jsp/addressbook.jsp
+++ b/apps/susidns/src/jsp/addressbook.jsp
@@ -23,6 +23,7 @@
  * $Revision: 1.3 $
  */
 %>
+<%@page pageEncoding="UTF-8"%>
 <%@ page contentType="text/html"%>
 <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
 <jsp:useBean id="version" class="i2p.susi.dns.VersionBean" scope="application" />
@@ -35,6 +36,7 @@
 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
 <html>
 <head>
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
 <title>${book.book} addressbook - susidns v${version.version}</title>
 <link rel="stylesheet" type="text/css" href="css.css">
 </head>
diff --git a/apps/susidns/src/jsp/config.jsp b/apps/susidns/src/jsp/config.jsp
index fd755300c6..415bec7556 100644
--- a/apps/susidns/src/jsp/config.jsp
+++ b/apps/susidns/src/jsp/config.jsp
@@ -23,6 +23,7 @@
  * $Revision: 1.1 $
  */
 %>
+<%@page pageEncoding="UTF-8"%>
 <%@ page contentType="text/html" %>
 <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
 <jsp:useBean id="version" class="i2p.susi.dns.VersionBean" scope="application"/>
@@ -31,6 +32,7 @@
 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
 <html>
 <head>
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
 <title>configuration - susidns v${version.version}</title>
 <link rel="stylesheet" type="text/css" href="css.css">
 </head>
diff --git a/apps/susidns/src/jsp/index.jsp b/apps/susidns/src/jsp/index.jsp
index 795dd7373b..581b638f9a 100644
--- a/apps/susidns/src/jsp/index.jsp
+++ b/apps/susidns/src/jsp/index.jsp
@@ -23,6 +23,7 @@
  * $Revision: 1.2 $
  */
 %>
+<%@page pageEncoding="UTF-8"%>
 <%@ page contentType="text/html"%>
 <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
 <jsp:useBean id="version" class="i2p.susi.dns.VersionBean" scope="application" />
@@ -30,6 +31,7 @@
 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
 <html>
 <head>
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
 <title><%=intl._("Introduction - SusiDNS")%> v${version.version}</title>
 <link rel="stylesheet" type="text/css" href="css.css">
 </head>
diff --git a/apps/susidns/src/jsp/subscriptions.jsp b/apps/susidns/src/jsp/subscriptions.jsp
index 75542d57da..a60710310f 100644
--- a/apps/susidns/src/jsp/subscriptions.jsp
+++ b/apps/susidns/src/jsp/subscriptions.jsp
@@ -23,6 +23,7 @@
  * $Revision: 1.2 $
  */
 %>
+<%@page pageEncoding="UTF-8"%>
 <%@ page contentType="text/html"%>
 <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
 <jsp:useBean id="version" class="i2p.susi.dns.VersionBean" scope="application" />
@@ -31,6 +32,7 @@
 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
 <html>
 <head>
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
 <title>subscriptions - susidns v${version.version}</title>
 <link rel="stylesheet" type="text/css" href="css.css">
 </head>
-- 
GitLab