Author: metskem
Date: Sun Aug 10 05:05:44 2008
New Revision: 684477
URL: http://svn.apache.org/viewvc?rev=684477&view=rev
Log:
JSPWIKI-320: removed all httpRequest.setCharacterEncoding() calls (except in
WikiServletFilter) because they were called too late, reported by Clay Atkins
Modified:
incubator/jspwiki/trunk/ChangeLog
incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/Release.java
incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/dav/WikiDavServlet.java
incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/Installer.java
incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/WikiServletFilter.java
incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/url/DefaultURLConstructor.java
incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/url/ShortURLConstructor.java
Modified: incubator/jspwiki/trunk/ChangeLog
URL:
http://svn.apache.org/viewvc/incubator/jspwiki/trunk/ChangeLog?rev=684477&r1=684476&r2=684477&view=diff
==============================================================================
--- incubator/jspwiki/trunk/ChangeLog (original)
+++ incubator/jspwiki/trunk/ChangeLog Sun Aug 10 05:05:44 2008
@@ -1,3 +1,10 @@
+2008-08-10 Harry Metske <[EMAIL PROTECTED]>
+
+ * 2.7.0-alpha-9
+
+ * JSPWIKI-320: removed all httpRequest.setCharacterEncoding() calls
(except in WikiServletFilter)
+ because they were called too late, reported by Clay Atkins
+
2008-07-31 Andrew Jaquith <ajaquith AT apache DOT org>
* 2.7.0-alpha-8
Modified: incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/Release.java
URL:
http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/Release.java?rev=684477&r1=684476&r2=684477&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/Release.java (original)
+++ incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/Release.java Sun Aug 10
05:05:44 2008
@@ -77,7 +77,7 @@
* <p>
* If the build identifier is empty, it is not added.
*/
- public static final String BUILD = "8";
+ public static final String BUILD = "9";
/**
* This is the generic version string you should use
Modified: incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/dav/WikiDavServlet.java
URL:
http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/dav/WikiDavServlet.java?rev=684477&r1=684476&r2=684477&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/dav/WikiDavServlet.java
(original)
+++ incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/dav/WikiDavServlet.java Sun
Aug 10 05:05:44 2008
@@ -167,7 +167,6 @@
// Do the "sanitize url" trick
// String p = new String(req.getPathInfo().getBytes("ISO-8859-1"),
"UTF-8");
- req.setCharacterEncoding( m_engine.getContentEncoding() );
String p = req.getPathInfo();
DavPath path = new DavPath( p );
Modified: incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/Installer.java
URL:
http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/Installer.java?rev=684477&r1=684476&r2=684477&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/Installer.java (original)
+++ incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/Installer.java Sun Aug 10
05:05:44 2008
@@ -192,9 +192,6 @@
m_session.getLocale() );
m_validated = false;
- // Set request encoding
- m_request.setCharacterEncoding("UTF-8");
-
try
{
InputStream in = null;
Modified:
incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/WikiServletFilter.java
URL:
http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/WikiServletFilter.java?rev=684477&r1=684476&r2=684477&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/WikiServletFilter.java
(original)
+++ incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/WikiServletFilter.java Sun
Aug 10 05:05:44 2008
@@ -118,7 +118,13 @@
return;
}
- if( m_engine.getBaseURL().length() == 0 &&
!((HttpServletRequest)request).getRequestURI().endsWith("Install.jsp") )
+ // If we haven't done so, wrap the request
+ HttpServletRequest httpRequest = (HttpServletRequest) request;
+
+ // Set the character encoding
+ httpRequest.setCharacterEncoding( m_engine.getContentEncoding() );
+
+ if( m_engine.getBaseURL().length() == 0 &&
!httpRequest.getRequestURI().endsWith("Install.jsp") )
{
PrintWriter out = response.getWriter();
@@ -135,8 +141,6 @@
return;
}
- // If we haven't done so, wrap the request and run the security filter
- HttpServletRequest httpRequest = (HttpServletRequest) request;
if ( !isWrapped( request ) )
{
// Prepare the WikiSession
@@ -155,9 +159,6 @@
throw new ServletException( e );
}
}
-
- // Set the character encoding
- httpRequest.setCharacterEncoding( m_engine.getContentEncoding() );
try
{
Modified:
incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/url/DefaultURLConstructor.java
URL:
http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/url/DefaultURLConstructor.java?rev=684477&r1=684476&r2=684477&view=diff
==============================================================================
---
incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/url/DefaultURLConstructor.java
(original)
+++
incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/url/DefaultURLConstructor.java
Sun Aug 10 05:05:44 2008
@@ -210,7 +210,6 @@
String encoding )
throws UnsupportedEncodingException
{
- request.setCharacterEncoding( encoding );
String pagereq = request.getParameter( "page" );
if( context.equals(WikiContext.ATTACH) )
Modified:
incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/url/ShortURLConstructor.java
URL:
http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/url/ShortURLConstructor.java?rev=684477&r1=684476&r2=684477&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/url/ShortURLConstructor.java
(original)
+++ incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/url/ShortURLConstructor.java
Sun Aug 10 05:05:44 2008
@@ -206,7 +206,6 @@
String encoding )
throws UnsupportedEncodingException
{
- request.setCharacterEncoding( encoding );
String pagereq = request.getParameter( "page" );
if( pagereq == null )