Logfiles are ordered by their id as follows:

LOGFILE_ERROR   = 1
LOGFILE_MESSAGE = 2
LOGFILE_TRACE   = 4

What is written to file n, will be written to all files m, m>n. Applies to user log writes. Some internal messages are such that they apply to one specific file, such as enable/disable notifications.
This commit is contained in:
vraatikka
2013-08-19 10:28:28 +03:00
parent 97b3da1d79
commit c2743e7543
3 changed files with 104 additions and 52 deletions

View File

@ -23,11 +23,11 @@ typedef struct fnames_conf_st fnames_conf_t;
typedef struct logmanager_st logmanager_t;
typedef enum {
LOGFILE_TRACE = 1,
LOGFILE_FIRST = LOGFILE_TRACE,
LOGFILE_ERROR = 1,
LOGFILE_FIRST = LOGFILE_ERROR,
LOGFILE_MESSAGE = 2,
LOGFILE_ERROR = 4,
LOGFILE_LAST = LOGFILE_ERROR
LOGFILE_TRACE = 4,
LOGFILE_LAST = LOGFILE_TRACE
} logfile_id_t;
typedef enum { FILEWRITER_INIT, FILEWRITER_RUN, FILEWRITER_DONE }