You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by fu...@apache.org on 2003/07/18 03:24:19 UTC
cvs commit: jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/valves ExtendedAccessLogValve.java
funkman 2003/07/17 18:24:19
Modified: catalina/src/share/org/apache/catalina/valves
ExtendedAccessLogValve.java
Log:
If bytes are requested, then print bytes, not the date.
Revision Changes Path
1.4 +11 -7 jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/valves/ExtendedAccessLogValve.java
Index: ExtendedAccessLogValve.java
===================================================================
RCS file: /home/cvs/jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/valves/ExtendedAccessLogValve.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- ExtendedAccessLogValve.java 4 Jun 2003 16:58:21 -0000 1.3
+++ ExtendedAccessLogValve.java 18 Jul 2003 01:24:19 -0000 1.4
@@ -637,9 +637,13 @@
result.append(timeTakenFormatter.format(runTime/1000d));
else if (FieldInfo.SPECIAL_TIME==fieldInfos[i].location)
result.append(timeFormatter.format(date));
- else if (FieldInfo.SPECIAL_BYTES==fieldInfos[i].location)
- result.append(dateFormatter.format(date));
- else if (FieldInfo.SPECIAL_CACHED==fieldInfos[i].location)
+ else if (FieldInfo.SPECIAL_BYTES==fieldInfos[i].location) {
+ int length = response.getContentCount();
+ if (length > 0)
+ result.append(length);
+ else
+ result.append("-");
+ } else if (FieldInfo.SPECIAL_CACHED==fieldInfos[i].location)
result.append('-'); /* I don't know how to evaluate this! */
else
result.append("?WTF?"); /* This should never happen! */
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org