From 32fca2d5b746b86bbbbd4f1b57064076cfc2ae4b Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Wed, 18 Jul 2012 13:10:09 +0200 Subject: journald: fix bad memory access After vacuuming we need to retrieve the journal file object again, since it might have changed. --- src/journal/journald.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src') diff --git a/src/journal/journald.c b/src/journal/journald.c index d8cfa66b75..c29d75c9c4 100644 --- a/src/journal/journald.c +++ b/src/journal/journald.c @@ -513,6 +513,10 @@ static void write_to_journal(Server *s, uid_t uid, struct iovec *iovec, unsigned server_vacuum(s); vacuumed = true; + f = find_journal(s, uid); + if (!f) + return; + log_info("Retrying write."); } } -- cgit v1.2.3-54-g00ecf