This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch 11.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/11.0.x by this push:
     new b6518bd871 Fix Javadoc warning
b6518bd871 is described below

commit b6518bd8711a99cf78e7f88ba0ed7d93da1e6669
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Mon Mar 10 10:48:05 2025 +0000

    Fix Javadoc warning
---
 java/org/apache/catalina/valves/ExtendedAccessLogValve.java | 10 ++++------
 1 file changed, 4 insertions(+), 6 deletions(-)

diff --git a/java/org/apache/catalina/valves/ExtendedAccessLogValve.java 
b/java/org/apache/catalina/valves/ExtendedAccessLogValve.java
index 268a56b414..e5483ecbad 100644
--- a/java/org/apache/catalina/valves/ExtendedAccessLogValve.java
+++ b/java/org/apache/catalina/valves/ExtendedAccessLogValve.java
@@ -91,18 +91,15 @@ public class ExtendedAccessLogValve extends AccessLogValve {
     // -------------------------------------------------------- Private Methods
 
     /**
-     * Wrap the incoming value with double quotes (") and escape any double 
quotes appearing in the value using two
-     * double quotes ("").
+     * Calls toString() on the object, wraps the result with double quotes (") 
and writes the result to the buffer. Any
+     * double quotes appearing in the value are escaped using two double 
quotes (""). If the value is null or if
+     * toString() fails, '-' will be written to the buffer.
      *
      * @param value - The value to wrap
      * @param buf the buffer to write to
-     *
-     * @return '-' if null. Otherwise, toString() will be called on the object 
and the value will be wrapped in quotes
-     *             and any quotes will be escaped with 2 sets of quotes.
      */
     static void wrap(Object value, CharArrayWriter buf) {
         String svalue;
-        // Does the value contain a " ? If so must encode it
         if (value == null || "-".equals(value)) {
             buf.append('-');
             return;
@@ -119,6 +116,7 @@ public class ExtendedAccessLogValve extends AccessLogValve {
 
         buf.append('\"');
         if (!svalue.isEmpty()) {
+            // Does the value contain a " ? If so must encode it
             escapeAndAppend(svalue, buf, true);
         }
         buf.append('\"');


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to