httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From b..@apache.org
Subject cvs commit: httpd-2.0/modules/loggers mod_log_forensic.c
Date Sat, 03 Jan 2004 14:35:21 GMT
ben         2004/01/03 06:35:21

  Modified:    modules/loggers mod_log_forensic.c
  Log:
  Use ap_assert().
  
  Revision  Changes    Path
  1.3       +6 -7      httpd-2.0/modules/loggers/mod_log_forensic.c
  
  Index: mod_log_forensic.c
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/modules/loggers/mod_log_forensic.c,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- mod_log_forensic.c	2 Jan 2004 23:35:59 -0000	1.2
  +++ mod_log_forensic.c	3 Jan 2004 14:35:21 -0000	1.3
  @@ -71,7 +71,6 @@
   #include "httpd.h"
   #include "http_config.h"
   #include "http_log.h"
  -#include <assert.h>
   #include "apr_strings.h"
   #include "apr_atomic.h"
   #include <unistd.h>
  @@ -156,9 +155,9 @@
   static char *log_escape(char *q, const char *e, const char *p)
   {
       for ( ; *p ; ++p) {
  -        assert(q < e);
  +        ap_assert(q < e);
           if (*p < ' ' || *p >= 0x7f || *p == '|' || *p == ':' || *p == '%') {
  -            assert(q+2 < e);
  +            ap_assert(q+2 < e);
               *q++ = '%';
               sprintf(q, "%02x", *(unsigned char *)p);
               q += 2;
  @@ -166,7 +165,7 @@
           else
               *q++ = *p;
       }
  -    assert(q < e);
  +    ap_assert(q < e);
       *q = '\0';
   
       return q;
  @@ -252,12 +251,12 @@
   
       apr_table_do(log_headers, &h, r->headers_in, NULL);
   
  -    assert(h.pos < h.end);
  +    ap_assert(h.pos < h.end);
       *h.pos++ = '\n';
   
       n = h.count-1;
       rv = apr_file_write(cfg->fd, h.log, &n);
  -    assert(rv == APR_SUCCESS && n == h.count-1);
  +    ap_assert(rv == APR_SUCCESS && n == h.count-1);
   
       apr_table_setn(r->notes, "forensic-id", id);
   
  @@ -281,7 +280,7 @@
       s = apr_pstrcat(r->pool, "-", id, "\n", NULL);
       l = n = strlen(s);
       rv = apr_file_write(cfg->fd, s, &n);
  -    assert(rv == APR_SUCCESS && n == l);
  +    ap_assert(rv == APR_SUCCESS && n == l);
   
       return OK;
   }
  
  
  

Mime
View raw message