Clean up log file handling. Fixes bug #63
authorAlan T. DeKok <aland@freeradius.org>
Fri, 26 Feb 2010 10:11:02 +0000 (11:11 +0100)
committerAlan T. DeKok <aland@freeradius.org>
Sat, 6 Mar 2010 07:51:55 +0000 (08:51 +0100)
commitb488a2c99a8502cec086cc93976f2a7cd70e9910
tree84fdb725233947cecd418b00fb789002f735f6bf
parent589a16877217e1877f21977827b25317a7e50b0f
Clean up log file handling.  Fixes bug #63

We now open the log file from the option parsing (-l file)
OR in mainconfig.c.  That way, the code in log.c can assume that
there is ALWAYS a log file, and it doesn't need to open one.  This
simplifies log.c substantially.

We also moved the syslog "openlog" code from log.c to mainconfig.c
This again makes it simpler.

On HUP, the hup_mainconfig() function takes care of re-opening the
log file.  This is so that the log.c functions don't have to do it.
src/main/event.c
src/main/mainconfig.c
src/main/radiusd.c