]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Bugzilla bug 102: Close useragent log on shutdown
authorhno <>
Sun, 20 May 2001 06:09:25 +0000 (06:09 +0000)
committerhno <>
Sun, 20 May 2001 06:09:25 +0000 (06:09 +0000)
src/main.cc
src/protos.h
src/useragent.cc

index 987e653aff0c40eb7b9ea936180ff47f986b2b20..5c3ec5b109231e057c148ebe907b54382a034204 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: main.cc,v 1.338 2001/05/19 19:32:02 hno Exp $
+ * $Id: main.cc,v 1.339 2001/05/20 00:09:25 hno Exp $
  *
  * DEBUG: section 1     Startup and Main Loop
  * AUTHOR: Harvest Derived
@@ -956,6 +956,7 @@ SquidShutdown(void *unused)
     storeDirSync();            /* Flush log writes */
     storeLogClose();
     accessLogClose();
+    useragentLogClose();
 #if WIP_FWD_LOG
     fwdUninit();
 #endif
index 78ad5a001b60eeb9abaf02a05b86df53cc2e996e..7a7863dfe9d49dda6a98cf86486ea2f0ddea0db8 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: protos.h,v 1.405 2001/05/08 15:24:35 hno Exp $
+ * $Id: protos.h,v 1.406 2001/05/20 00:09:25 hno Exp $
  *
  *
  * SQUID Web Proxy Cache          http://www.squid-cache.org/
@@ -1109,6 +1109,7 @@ extern void urlExtMethodConfigure(void);
 extern void useragentOpenLog(void);
 extern void useragentRotateLog(void);
 extern void logUserAgent(const char *, const char *);
+extern void useragentLogClose(void);
 extern void refererOpenLog(void);
 extern void refererRotateLog(void);
 extern void logReferer(const char *, const char *, const char *);
index c6bcc7a3640b974bef11e9ca2f2fc99b28a91233..bca728bfacf7168c5bd7e4d48769808c7877d681 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: useragent.cc,v 1.24 2001/03/04 00:50:26 wessels Exp $
+ * $Id: useragent.cc,v 1.25 2001/05/20 00:09:25 hno Exp $
  *
  * DEBUG: section 40    User-Agent logging
  * AUTHOR: Joe Ramey <ramey@csc.ti.com>
@@ -82,3 +82,12 @@ logUserAgent(const char *client, const char *agent)
        agent);
 #endif
 }
+
+void
+useragentLogClose(void)
+{
+#if USE_USERAGENT_LOG
+    logfileClose(useragentlog);
+    useragentlog = NULL;
+#endif
+}