summaryrefslogtreecommitdiff
path: root/src/journal/sd-journal.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2012-10-16 22:59:28 +0200
committerLennart Poettering <lennart@poettering.net>2012-10-16 22:59:28 +0200
commit44a5fa34d9f9a5050cdf4a497e6ccf5af2d1678d (patch)
tree2c3d58def7c74e8234b2bf85105d5fb93a22b343 /src/journal/sd-journal.c
parent4b69bfdb5bb51db7583de6dc0ecc337b77921f6b (diff)
sd-journal: fix bad memory access
Diffstat (limited to 'src/journal/sd-journal.c')
-rw-r--r--src/journal/sd-journal.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/journal/sd-journal.c b/src/journal/sd-journal.c
index 88b382f4cc..99ac1fd4ef 100644
--- a/src/journal/sd-journal.c
+++ b/src/journal/sd-journal.c
@@ -1258,11 +1258,13 @@ static int remove_file(sd_journal *j, const char *prefix, const char *filename)
return 0;
hashmap_remove(j->files, f->path);
+
+ log_debug("File %s got removed.", f->path);
+
journal_file_close(f);
j->current_invalidate_counter ++;
- log_debug("File %s got removed.", f->path);
return 0;
}