Re: s6-log n0 still creating archives

From: Laurent Bercot <ska-supervision_at_skarnet.org>
Date: Sun, 23 Mar 2014 18:58:25 +0000

  OK, easy one: n was stupidly enforced as 2 or more.
  Thanks for the report and the trace.

  It's not possible to ignore the archive processor even with n0,
because processors may have side effects on the state files, and
may also do things like send the "current" file to other log
processing software, without local archiving - typically for
network logging. s6-log will process and create the archive file
in any case, then examine the directory and delete the archives
by creation time until there's only n left.

  Until the next s6 release, this patch should fix the behaviour.

-- 
  Laurent
--- src.old/daemontools-extras/s6-log.c
+++ src/daemontools-extras/s6-log.c
_at_@ -752,7 +752,6 @@
        case 'n' :
        {
          if (!uint320_scan(*argv + 1, &cur_n)) goto fail ;
-        if (cur_n < 2) cur_n = 2 ;
          break ;
        }
        case 's' :
Received on Sun Mar 23 2014 - 18:58:25 UTC

This archive was generated by hypermail 2.3.0 : Sun May 09 2021 - 19:44:18 UTC