bozo: create a syslog connection only if the -syslog option is given
authorMichael Meffie <mmeffie@sinenomine.net>
Wed, 21 Jan 2015 19:42:47 +0000 (14:42 -0500)
committerBenjamin Kaduk <kaduk@mit.edu>
Wed, 18 Nov 2015 05:03:58 +0000 (00:03 -0500)
commit11468ae0e12a627a8802711e8562948828834f06
tree35ecaf805b9d08076115c7bf41a30c783c8a95f7
parent15e8678661ec49f5eac3954defad84c06b3e0164
bozo: create a syslog connection only if the -syslog option is given

Fix a minor bug in which an unnecessary syslog connection is opened when
the BosLog is not present (typically, the first time the bosserver is
started) or when the BosLog is a named pipe, even if the -syslog option
was not given.

This bug was introduced in commit bdc7e43117706d0aa46d3b6435489e9d4c2b0888,
which added checks to avoid renaming logs when they are named pipes.

lstat() and S_ISFIFO are provided by libroken, so do not need to be hidden
behind conditional compilation.

Change-Id: I828534be69949fe017cc7dbed1b6798aa4c0ba17
Reviewed-on: http://gerrit.openafs.org/11686
Reviewed-by: Perry Ruiter <pruiter@sinenomine.net>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
src/bozo/bosserver.c