systemd/0226-journal-file-Fix-return-value-in-bump_entry_array.patch
Jan Macku 54fa34c9c2 systemd-252-8
Resolves: #2173682
2023-02-27 17:36:21 +01:00

27 lines
1.0 KiB
Diff

From acf4f21936ad6153ba53f2d798967e57473be8bc Mon Sep 17 00:00:00 2001
From: Daan De Meyer <daan.j.demeyer@gmail.com>
Date: Thu, 23 Feb 2023 15:40:38 +0100
Subject: [PATCH] journal-file: Fix return value in bump_entry_array()
(cherry picked from commit 0399902440fbaea5b163254f70be57dbedb7131e)
Resolves: #2173682
---
src/libsystemd/sd-journal/journal-file.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/libsystemd/sd-journal/journal-file.c b/src/libsystemd/sd-journal/journal-file.c
index c1ec6bb1d8..c489436a1e 100644
--- a/src/libsystemd/sd-journal/journal-file.c
+++ b/src/libsystemd/sd-journal/journal-file.c
@@ -2410,7 +2410,8 @@ static int bump_entry_array(
if (direction == DIRECTION_DOWN) {
assert(o);
- return le64toh(o->entry_array.next_entry_array_offset);
+ *ret = le64toh(o->entry_array.next_entry_array_offset);
+ return 0;
}
/* Entry array chains are a singly linked list, so to find the previous array in the chain, we have