multilog alert advice

"alfa bet" <[email protected]>
Newsgroups gmane.comp.djb.syslog
Message-ID <[email protected]>
Hi

I don't want to use a pipe for stderr and a program to read it,
so I add "flagforcerotate = 1;" in multilog.c (see below).

I want the action "e" alert to trigger log rotation.
...
exec multilog t !processor ./main '-*' '+* event*' e
...

multilog writes lines in current and when event occurs or size of current big enough
runs processor which writes some local archives, sends mail to network central log for further processing.

Everything works as I want ,in my tests, with my modification, 
but I am not good at programming and can somebody tell me if I broke something
in multilog?

bash-3.00# diff -c multilog.c.orig /package/admin/daemontools/src/multilog.c
*** multilog.c.orig     2006-03-15 12:44:16.000000000 +0200
--- /package/admin/daemontools/src/multilog.c   2006-03-15 15:37:56.000000000 +0200
***************
*** 548,553 ****
--- 548,554 ----
                buffer_puts(buffer_2,"\n");
              }
              buffer_flush(buffer_2);
+             flagforcerotate = 1;
            }
            break;
          case '=':

Regards
Florin



-- 
___________________________________________________
Play 100s of games for FREE! http://games.mail.com/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.