From ed9d3e92d6e588cd7af5f6a23cdcd10d9eb99c73 Mon Sep 17 00:00:00 2001 From: hno <> Date: Thu, 22 Jun 2000 02:34:37 +0000 Subject: [PATCH] Fixed a bug where --enable-useragent-log caused Squid to coredump unless useragent_log was specified in squid.conf --- src/useragent.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/useragent.cc b/src/useragent.cc index be604f927b..3f978dd690 100644 --- a/src/useragent.cc +++ b/src/useragent.cc @@ -1,6 +1,6 @@ /* - * $Id: useragent.cc,v 1.20 2000/03/14 23:07:51 wessels Exp $ + * $Id: useragent.cc,v 1.21 2000/06/21 20:34:37 hno Exp $ * * DEBUG: section 40 User-Agent logging * AUTHOR: Joe Ramey @@ -44,7 +44,7 @@ useragentOpenLog(void) { #if USE_USERAGENT_LOG assert(NULL == useragentlog); - if (0 == strcmp(Config.Log.useragent, "none")) { + if (!Config.Log.useragent || (0 == strcmp(Config.Log.useragent, "none"))) { debug(40, 1) ("User-Agent logging is disabled.\n"); return; } -- 2.47.3