mirror of
https://github.com/freebsd/freebsd-src
synced 2024-11-02 19:51:25 +00:00
d556719e15
Console and tty descriptors are initially opened in parse_action() to
determine whether they are valid using isatty(). That descriptor is then
closed because it is never accessed by syslogd again; ttymsg() will reopen
the tty/console under a new descriptor when needed.
If the user attempts to log to a tty that is inactive outside of
syslogd, then syslogd must keep that descriptor open so the tty remains
accessible. For example, logging to `/dev/ttyvb` requires the initial
`/dev/ttyvb` descriptor to stay open so the user can view its buffer at
any time via CTRL+ALT+F12.
As a result, console and tty descriptors must remain open until a
potential configuration reload or a system shutdown. The given
descriptor will be closed in close_filed() in such circumstances.
PR: 274454
Fixes:
|
||
---|---|---|
.. | ||
tests | ||
ftp.conf | ||
lpr.conf | ||
Makefile | ||
Makefile.depend | ||
pathnames.h | ||
ppp.conf | ||
syslog.conf | ||
syslog.conf.5 | ||
syslogd.8 | ||
syslogd.c |