aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src/log.c
diff options
context:
space:
mode:
authorEgor Tensin <egor@tensin.name>2026-06-12 17:20:08 +0200
committerEgor Tensin <egor@tensin.name>2026-06-12 17:20:08 +0200
commit1160cdb21e0b667269299853cb47a4aa88948dc3 (patch)
treeb6828fc587bf0f868d9eb7a54518a46a9afc1a32 /src/log.c
parentdependabot: fix a typo (diff)
downloadcimple-1160cdb21e0b667269299853cb47a4aa88948dc3.tar.gz
cimple-1160cdb21e0b667269299853cb47a4aa88948dc3.zip
unify my .clang-format files
Diffstat (limited to 'src/log.c')
-rw-r--r--src/log.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/src/log.c b/src/log.c
index 4212c84..1761523 100644
--- a/src/log.c
+++ b/src/log.c
@@ -14,8 +14,7 @@
int g_log_lvl = LOG_LVL_INFO;
-static inline void log_prefix_timestamp(FILE *dest)
-{
+static inline void log_prefix_timestamp(FILE* dest) {
struct timeval tv;
struct tm tm;
char buf[64];
@@ -33,13 +32,11 @@ static inline void log_prefix_timestamp(FILE *dest)
fprintf(dest, "%s", buf);
}
-static inline void log_prefix_thread_id(FILE *dest)
-{
+static inline void log_prefix_thread_id(FILE* dest) {
fprintf(dest, "%d | ", gettid());
}
-int log_entry_start(int lvl, FILE *dest)
-{
+int log_entry_start(int lvl, FILE* dest) {
if (lvl < g_log_lvl)
return 0;
flockfile(dest);
@@ -48,7 +45,6 @@ int log_entry_start(int lvl, FILE *dest)
return 1;
}
-void log_entry_end(FILE *dest)
-{
+void log_entry_end(FILE* dest) {
funlockfile(dest);
}