Another tweak to syslog_circular_buffer()

Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
Tom Eastep 2015-11-03 18:59:10 -08:00
parent 3890a5c1fd
commit ca0ac0473c

View File

@ -143,9 +143,18 @@ timed_read ()
} }
# #
# Determine if 'syslog -C' is running # Determine if 'syslogd -C' or logd -S is running
# #
find_logger() { syslog_circular_buffer() {
local pid
local tty
local flags
local time
local path
local args
local arg
ps w 2> /dev/null | (
while read pid tty stat time path args; do while read pid tty stat time path args; do
case $path in case $path in
syslogd|*/syslogd) syslogd|*/syslogd)
@ -169,19 +178,7 @@ find_logger() {
esac esac
done done
return 1 return 1 )
}
syslog_circular_buffer() {
local pid
local tty
local flags
local time
local path
local args
local arg
ps w 2> /dev/null | find_logger
} }
setup_logread() { setup_logread() {