summaryrefslogtreecommitdiff
path: root/src/journal/sd-journal.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/journal/sd-journal.c')
-rw-r--r--src/journal/sd-journal.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/journal/sd-journal.c b/src/journal/sd-journal.c
index 9bc426faf8..9dea5470be 100644
--- a/src/journal/sd-journal.c
+++ b/src/journal/sd-journal.c
@@ -1178,8 +1178,7 @@ static bool file_type_wanted(int flags, const char *filename) {
if (flags & SD_JOURNAL_CURRENT_USER) {
char prefix[5 + DECIMAL_STR_MAX(uid_t) + 1];
- assert_se(snprintf(prefix, sizeof(prefix), "user-"UID_FMT, getuid())
- < (int) sizeof(prefix));
+ xsprintf(prefix, "user-"UID_FMT, getuid());
if (file_has_type_prefix(prefix, filename))
return true;