Re: [PATCH v2] git daemon: avoid calling syslog() from a signal handler
- From
Stephen R. van den Berg <srb@cuci.nl>
- Date
- Jul 7, 2008, 06:54 UTC
- Message-ID
- <20080707065439.GA25877@cuci.nl>
- In-Reply-To
- <7vmykua2et.fsf@gitster.siamese.dyndns.org>
Junio C Hamano wrote:
>Another thing we might want to consider to make this logic much more >simpler would be to move everything out of child_handler(), except the >write() whose sole purpose is to allow us break out of the poll().
As a general rule, keep the work done in a signal handler down to the bare minimum (like setting an integer flag, and perhaps unblocking the main thread through a write to this signallingpipe).
--
Sincerely,
Stephen R. van den Berg.
A truly wise man never plays leapfrog with a unicorn.