summaryrefslogtreecommitdiffstats
path: root/usr.sbin/syslogd/ttymsg.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* stop including sys/param.h for nitems. define locally as needed.tedu2016-08-161-2/+5
| | | | ok natano reyk
* Eliminate superfluous 3rd params in fcntl(F_GETFL) calls.krw2016-04-021-2/+1
| | | | | | | | | | | | ttymsg.c doesn't need to include fcntl.h. Tweak standard fd sanitising to be more like the sanitise_stdfd() used elsewhere, though other uses of 'nullfd' make importing sanitise_stdfd() itself unappetizing. Add a die(0) if dup2() fails. suggestions & ok bluhm@
* If writing to a tty blocks, syslogd forked and tried to write againbluhm2015-10-231-29/+72
| | | | | | | | in a background process. A potential fork(2) at every message is bad, so replace this with an event. As a bonus the syslogd child process does not need to pledge "proc" anymore. Also limit the number of delayed write events. OK deraadt@
* Do some cleanup in syslogd ttymsg(). Add a debug message when thebluhm2015-10-211-26/+29
| | | | | syslogd child calls fork(2) to delay blocked output. OK benno@
* Remove some unneeded includes. OK deraadt@millert2015-07-061-3/+1
|
* Replace <sys/param.h> with <limits.h> and other less dirty headers wherederaadt2015-01-161-2/+2
| | | | | | | | | possible. Annotate <sys/param.h> lines with their current reasons. Switch to PATH_MAX, NGROUPS_MAX, HOST_NAME_MAX+1, LOGIN_NAME_MAX, etc. Change MIN() and MAX() to local definitions of MINIMUM() and MAXIMUM() where sensible to avoid pulling in the pollution. These are the files confirmed through binary verification. ok guenther, millert, doug (helped with the verification protocol)
* Fix the gcc compiler warnings "comparison between signed andbluhm2014-08-251-5/+8
| | | | | | unsigned". Some checks got stricter. The (size_t) cast is only done, if the argument is not negative. OK henning@
* rcsid[] and sccsid[] and copyright[] are essentially unmaintained (andderaadt2009-10-271-8/+1
| | | | | | | unmaintainable). these days, people use source. these id's do not provide any benefit, and do hurt the small install media (the 33,000 line diff is essentially mechanical) ok with the idea millert, ok dms
* -Wall,-Wshadow cleanup with avsm@; ok henning@ krw@djm2004-07-031-3/+3
|
* correct error message (wall -> syslogd)avsm2003-08-271-3/+3
|
* Privilege separated syslog daemon. The child listening to log requests dropsavsm2003-07-311-0/+175
to user _syslogd and chroots itself, while the privileged parent grants it access to open logfiles and other calls it needs. The only difference from existing behaviour is that if syslog.conf changes and syslogd receives a HUP, it will re-exec itself and have two new PIDs. A HUP with an unchanged config will make syslogd reopen logfiles as before. Lots of help and code from deraadt@ , and advice from millert@ Various versions tested by todd, cloder, mpech, markus, tdeval and others