This is an automated email from the ASF dual-hosted git repository.
markt pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/main by this push:
new f495c46 Clean-up. Fix indents.
f495c46 is described below
commit f495c461ecc881a4b21a40c1b1994ebdfdc7af31
Author: Mark Thomas <[email protected]>
AuthorDate: Thu Jun 3 16:52:16 2021 +0100
Clean-up. Fix indents.
---
java/jakarta/servlet/http/HttpServlet.java | 26 +++++++++-----------------
1 file changed, 9 insertions(+), 17 deletions(-)
diff --git a/java/jakarta/servlet/http/HttpServlet.java
b/java/jakarta/servlet/http/HttpServlet.java
index 15ad35c..9c001b6 100644
--- a/java/jakarta/servlet/http/HttpServlet.java
+++ b/java/jakarta/servlet/http/HttpServlet.java
@@ -87,10 +87,8 @@ public abstract class HttpServlet extends GenericServlet {
private static final String HEADER_IFMODSINCE = "If-Modified-Since";
private static final String HEADER_LASTMOD = "Last-Modified";
- private static final String LSTRING_FILE =
- "jakarta.servlet.http.LocalStrings";
- private static final ResourceBundle lStrings =
- ResourceBundle.getBundle(LSTRING_FILE);
+ private static final String LSTRING_FILE =
"jakarta.servlet.http.LocalStrings";
+ private static final ResourceBundle lStrings =
ResourceBundle.getBundle(LSTRING_FILE);
private final Object cachedAllowHeaderValueLock = new Object();
private volatile String cachedAllowHeaderValue = null;
@@ -509,13 +507,9 @@ public abstract class HttpServlet extends GenericServlet {
Method[] thisMethods = c.getDeclaredMethods();
if ((parentMethods != null) && (parentMethods.length > 0)) {
- Method[] allMethods =
- new Method[parentMethods.length + thisMethods.length];
- System.arraycopy(parentMethods, 0, allMethods, 0,
- parentMethods.length);
- System.arraycopy(thisMethods, 0, allMethods, parentMethods.length,
- thisMethods.length);
-
+ Method[] allMethods = new Method[parentMethods.length +
thisMethods.length];
+ System.arraycopy(parentMethods, 0, allMethods, 0,
parentMethods.length);
+ System.arraycopy(thisMethods, 0, allMethods, parentMethods.length,
thisMethods.length);
thisMethods = allMethods;
}
@@ -602,8 +596,8 @@ public abstract class HttpServlet extends GenericServlet {
int responseLength;
String CRLF = "\r\n";
- StringBuilder buffer = new StringBuilder("TRACE
").append(req.getRequestURI())
- .append(" ").append(req.getProtocol());
+ StringBuilder buffer =
+ new StringBuilder("TRACE
").append(req.getRequestURI()).append(" ").append(req.getProtocol());
Enumeration<String> reqHeaderEnum = req.getHeaderNames();
@@ -908,10 +902,8 @@ class NoBodyResponse extends HttpServletResponseWrapper {
// file private
class NoBodyOutputStream extends ServletOutputStream {
- private static final String LSTRING_FILE =
- "jakarta.servlet.http.LocalStrings";
- private static final ResourceBundle lStrings =
- ResourceBundle.getBundle(LSTRING_FILE);
+ private static final String LSTRING_FILE =
"jakarta.servlet.http.LocalStrings";
+ private static final ResourceBundle lStrings =
ResourceBundle.getBundle(LSTRING_FILE);
private final HttpServletResponse response;
private boolean flushed = false;
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]