Rename enum log_level to libseat_log_level
This is preparatory work for exposing a public function to set libseat's log handler.
This commit is contained in:
parent
ab4b961492
commit
a254fe3692
4 changed files with 41 additions and 37 deletions
|
@ -38,14 +38,14 @@ struct libseat *libseat_open_seat(struct libseat_seat_listener *listener, void *
|
|||
}
|
||||
|
||||
char *loglevel = getenv("LIBSEAT_LOGLEVEL");
|
||||
enum log_level level = LOGLEVEL_SILENT;
|
||||
enum libseat_log_level level = LIBSEAT_LOG_LEVEL_SILENT;
|
||||
if (loglevel != NULL) {
|
||||
if (strcmp(loglevel, "silent") == 0) {
|
||||
level = LOGLEVEL_SILENT;
|
||||
level = LIBSEAT_LOG_LEVEL_SILENT;
|
||||
} else if (strcmp(loglevel, "info") == 0) {
|
||||
level = LOGLEVEL_INFO;
|
||||
level = LIBSEAT_LOG_LEVEL_INFO;
|
||||
} else if (strcmp(loglevel, "debug") == 0) {
|
||||
level = LOGLEVEL_DEBUG;
|
||||
level = LIBSEAT_LOG_LEVEL_DEBUG;
|
||||
}
|
||||
}
|
||||
log_init(level);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue