summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormrb0nk500 <b0nk@b0nk.xyz>2022-08-03 15:50:45 -0300
committermrb0nk500 <b0nk@b0nk.xyz>2022-08-03 15:50:45 -0300
commit9e4d29fbc2a285ee805836267b955fecc96c0377 (patch)
treeff0e4e005ce40aecd299fa922c89d5a35002a9b4
parenteaf8f4225d1c865dd9006a09059fefcd941bff63 (diff)
macros: Add `const_strlen()` macro
-rw-r--r--macros.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/macros.h b/macros.h
index 5f4c523..56c8ccc 100644
--- a/macros.h
+++ b/macros.h
@@ -5,5 +5,6 @@
#define log(priority, ...) printlog(LOG_OUT_SYSLOG, priority, __VA_ARGS__)
#define log_reason(priority, msg, ...) log(priority, msg " Reason %s", __VA_ARGS__)
+#define const_strlen(str) sizeof((char []){str})
#endif