[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
duplicate message
From: |
Martin Pala |
Subject: |
duplicate message |
Date: |
Tue, 17 Dec 2002 21:45:25 +0100 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2.1) Gecko/20021210 Debian/1.2.1-3 |
What about following code:
(monitor.c:)
...
log("Starting %s daemon\n", prog);
if(! Run.debug) printf("Starting %s daemon\n", prog);
...
It makes following output in debug mode:
unicorn:~/cvs/monit.cvs-20021217# ./monit -c /etc/monitrc
Starting monit daemon
Starting monit daemon
Starting httpd at [127.0.0.1:2812]
There is duplicated "Starting monit daemon" message. I think that we
discussed it in the past and for some reason we let it in the code.
After changing error->log i think we can maybe avoid it => remove:
if(! Run.debug) printf("Starting %s daemon\n", prog);
because if monit has tty, it will print the message to standard output
as well.
What do you think?
Martin
- duplicate message,
Martin Pala <=