diff options
author | Michael Vetter <jubalh@iodoru.org> | 2022-06-22 12:52:30 +0200 |
---|---|---|
committer | Michael Vetter <jubalh@iodoru.org> | 2022-06-22 13:05:11 +0200 |
commit | ff8065eaca84b26d8d6de7bbaa03420204b36764 (patch) | |
tree | 0dce4f328febf203ff84a9e1f3a509714e1549ec | |
parent | 5c0c386ffa8cc0580f1e92250081f730ff3dc930 (diff) | |
download | profani-tty-ff8065eaca84b26d8d6de7bbaa03420204b36764.tar.gz |
Rename _log_string_from_level to _log_abbreviation_string_from_level
-rw-r--r-- | src/log.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/log.c b/src/log.c index 867e0bb9..6aeb6ecf 100644 --- a/src/log.c +++ b/src/log.c @@ -89,7 +89,7 @@ static void _free_chat_log(struct dated_chat_log* dated_log); static gboolean _key_equals(void* key1, void* key2); static char* _get_log_filename(const char* const other, const char* const login, GDateTime* dt, gboolean is_room); static void _rotate_log_file(void); -static char* _log_string_from_level(log_level_t level); +static char* _log_abbreviation_string_from_level(log_level_t level); static void _chat_log_chat(const char* const login, const char* const other, const gchar* const msg, chat_log_direction_t direction, GDateTime* timestamp, const char* const resourcepart); static void _groupchat_log_chat(const gchar* const login, const gchar* const room, const gchar* const nick, @@ -189,7 +189,7 @@ log_msg(log_level_t level, const char* const area, const char* const msg) if (level >= level_filter && logp) { GDateTime* dt = g_date_time_new_now_local(); - char* level_str = _log_string_from_level(level); + char* level_str = _log_abbreviation_string_from_level(level); gchar* date_fmt = g_date_time_format_iso8601(dt); @@ -700,8 +700,9 @@ _get_log_filename(const char* const other, const char* const login, GDateTime* d return logfile_path; } +// abbreviation string is the prefix thats used in the log file static char* -_log_string_from_level(log_level_t level) +_log_abbreviation_string_from_level(log_level_t level) { switch (level) { case PROF_LEVEL_ERROR: |