>
> > > +               freopen(opt_logfile, "w", stderr);
> >
> > unnecessary things here.
>
> Yes, extra close and dup2. Two microseconds wasted per each acpid startup.
> Horror. ;)


:)) No. It closes fd 2 (or dup's /dev/null to fd 2). Then, if freopen()
fails, we do not see ANY output... That is my concern...

> Personally, I use acpid as runit service. Daemonizing was requested as it
> is
> > "default behaviour of big brother".
>
> Then it's ok.


I still can't help feeling we should not daemonize/use-custom-log-file at
all. Where is KISS?! Vote pro or contra, please...

Yes, in the code above SIGTERM will not kill it either.
> It will exit only after poll() will see some input,
> and THEN program will notice what SIGTERM was received.


Weird. I start and stop it by means of sv, and it works...

--
Vladimir
_______________________________________________
busybox mailing list
[email protected]
http://busybox.net/cgi-bin/mailman/listinfo/busybox

Reply via email to