summaryrefslogtreecommitdiff
path: root/src/journal/coredump.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2016-01-26 13:48:57 +0100
committerLennart Poettering <lennart@poettering.net>2016-01-26 14:43:24 +0100
commit4850d39ab72e7cb00a6e9c9aa4745c997674efa6 (patch)
treed2fb7c6736289a78c3b7170ccdb659360745f3f5 /src/journal/coredump.c
parentd6f4302b66fb8847dd79cdf7ea35b9eeccac8aff (diff)
journald: add a couple of static asserts checking logging constants
Whenever we include a log level or facility in a journal string field, make sure the compiler checks for us that that's actually the right thing to do.
Diffstat (limited to 'src/journal/coredump.c')
-rw-r--r--src/journal/coredump.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/journal/coredump.c b/src/journal/coredump.c
index 7df59fe29b..8298b02439 100644
--- a/src/journal/coredump.c
+++ b/src/journal/coredump.c
@@ -794,6 +794,8 @@ int main(int argc, char* argv[]) {
IOVEC_SET_STRING(iovec[j++], core_timestamp);
IOVEC_SET_STRING(iovec[j++], "MESSAGE_ID=fc2e22bc6ee647b6b90729ab34a250b1");
+
+ assert_cc(2 == LOG_CRIT);
IOVEC_SET_STRING(iovec[j++], "PRIORITY=2");
/* Vacuum before we write anything again */