From 5e0c35a3bd9281d1a32d0644a8302d476c5d93af Mon Sep 17 00:00:00 2001 From: Art Cancro Date: Tue, 7 Jun 2005 00:40:11 +0000 Subject: [PATCH] *** empty log message *** --- webcit/context_loop.c | 4 ++++ webcit/groupdav_put.c | 3 ++- webcit/webserver.c | 4 +++- 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/webcit/context_loop.c b/webcit/context_loop.c index 9fd9ba8fe..dc5825cb3 100644 --- a/webcit/context_loop.c +++ b/webcit/context_loop.c @@ -286,12 +286,16 @@ void context_loop(int sock) /* * Can we compress? + * (Don't compress if HTTP_TRACING is active, because + * the compressed data obviously doesn't log well.) */ +#ifndef HTTP_TRACING if (!strncasecmp(buf, "Accept-encoding:", 16)) { if (strstr(&buf[16], "gzip")) { gzip_ok = 1; } } +#endif /* HTTP_TRACING */ /* * Browser-based sessions use cookies for session authentication diff --git a/webcit/groupdav_put.c b/webcit/groupdav_put.c index 8cec2d450..85a65c2da 100644 --- a/webcit/groupdav_put.c +++ b/webcit/groupdav_put.c @@ -83,7 +83,8 @@ void groupdav_put(char *dav_pathname, char *dav_ifmatch, lprintf(9, "old_msgnum: %ld\n", old_msgnum); if (atol(dav_ifmatch) != old_msgnum) { wprintf("HTTP/1.1 412 Precondition Failed\r\n"); - lprintf(9, "HTTP/1.1 412 Precondition Failed\r\n"); + lprintf(9, "HTTP/1.1 412 Precondition Failed (ifmatch=%ld, old_msgnum=%ld)\r\n", + atol(dav_ifmatch), old_msgnum); groupdav_common_headers(); wprintf("Content-Length: 0\r\n\r\n"); return; diff --git a/webcit/webserver.c b/webcit/webserver.c index e43cd89fb..27f6c91a2 100644 --- a/webcit/webserver.c +++ b/webcit/webserver.c @@ -9,8 +9,8 @@ /* * Uncomment to dump an HTTP trace to stderr -#define HTTP_TRACING 1 */ +#define HTTP_TRACING 1 #include #include @@ -275,6 +275,7 @@ void end_burst(void) WC->burst_len = 0; WC->burst = NULL; +#ifndef HTTP_TRACING #ifdef HAVE_ZLIB /* Handle gzip compression */ if (WC->gzip_ok) { @@ -297,6 +298,7 @@ void end_burst(void) } } #endif /* HAVE_ZLIB */ +#endif /* HTTP_TRACING */ wprintf("Content-length: %d\r\n\r\n", the_len); client_write(the_data, the_len); -- 2.39.2