summaryrefslogtreecommitdiff
path: root/src/test
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2018-06-04 12:59:22 +0200
committerSven Eden <yamakuzure@gmx.net>2018-08-24 16:47:08 +0200
commit74102fa68ea25cd7e8914f112f357760130728fb (patch)
treed07112608de6fb911e0cdde0dbcc9cc28f081e8e /src/test
parent2ec9aee55b39af874d9582d3884c02f43d6c98fe (diff)
basic/log: add the log_struct terminator to macro
This way all callers do not need to specify it. Exhaustively tested by running test-log under valgrind ;)
Diffstat (limited to 'src/test')
-rw-r--r--src/test/test-log.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/test/test-log.c b/src/test/test-log.c
index fe2e805b7..a09439c79 100644
--- a/src/test/test-log.c
+++ b/src/test/test-log.c
@@ -30,22 +30,19 @@ assert_cc((LOG_REALM_PLUS_LEVEL(LOG_REALM_UDEV, LOG_USER | LOG_INFO) & LOG_PRIMA
static void test_log_console(void) {
log_struct(LOG_INFO,
"MESSAGE=Waldo PID="PID_FMT, getpid_cached(),
- "SERVICE=piepapo",
- NULL);
+ "SERVICE=piepapo");
}
static void test_log_journal(void) {
log_struct(LOG_INFO,
"MESSAGE=Foobar PID="PID_FMT, getpid_cached(),
- "SERVICE=foobar",
- NULL);
+ "SERVICE=foobar");
log_struct(LOG_INFO,
"MESSAGE=Foobar PID="PID_FMT, getpid_cached(),
"FORMAT_STR_TEST=1=%i A=%c 2=%hi 3=%li 4=%lli 1=%p foo=%s 2.5=%g 3.5=%g 4.5=%Lg",
(int) 1, 'A', (short) 2, (long int) 3, (long long int) 4, (void*) 1, "foo", (float) 2.5f, (double) 3.5, (long double) 4.5,
- "SUFFIX=GOT IT",
- NULL);
+ "SUFFIX=GOT IT");
}
static void test_long_lines(void) {