conf: create directories before dropping root

Create logdir and dumpdir before dropping root. Set their uid/gid to the
user chronyd will switch to. This allows chronyd to create the
directories in a directory where the user won't have write permissions
(e.g. /var/lib).
This commit is contained in:
Miroslav Lichvar
2015-08-10 17:02:12 +02:00
parent e7100e106d
commit 6d42dd8603
6 changed files with 29 additions and 30 deletions

View File

@@ -142,7 +142,6 @@ extern LOG_FileID LOG_FileOpen(const char *name, const char *banner);
FORMAT_ATTRIBUTE_PRINTF(2, 3)
extern void LOG_FileWrite(LOG_FileID id, const char *format, ...);
extern void LOG_CreateLogFileDir(void);
extern void LOG_CycleLogFiles(void);
#endif /* GOT_LOGGING_H */