Log a single dash (`-') if referer or user-agent header is missing/unknown

This commit is contained in:
interp 2003-02-25 17:36:36 +00:00
parent 862dd31c88
commit d5dcbace37
1 changed files with 3 additions and 3 deletions

View File

@ -136,7 +136,7 @@
(define (get-header headers tag)
(cond
((assq tag headers) => cdr)
(else "unknown")))
(else #f)))
;; does the log-file rotation on signal USR1
(define (make-log-file-rotator log-file http-log-lock)
@ -176,10 +176,10 @@
; Files conform to CLF are expected to print the original line.
(or http-code "-")
(or filesize "-")
(if (string? referer) (string-trim referer) "")
(if (string? referer) (string-trim referer) '-)
(if (string? user-agent)
(string-trim user-agent char-set:whitespace)
"")))
'-)))
(define (maybe-dns-lookup remote-ip)