summaryrefslogtreecommitdiff
path: root/src/journal
diff options
context:
space:
mode:
Diffstat (limited to 'src/journal')
-rw-r--r--src/journal/journal-file.c2
-rw-r--r--src/journal/journald-server.c12
-rw-r--r--src/journal/sd-journal.c6
-rw-r--r--src/journal/test-journal-flush.c2
-rw-r--r--src/journal/test-journal-interleaving.c2
-rw-r--r--src/journal/test-journal-stream.c6
-rw-r--r--src/journal/test-journal-verify.c6
-rw-r--r--src/journal/test-journal.c10
8 files changed, 23 insertions, 23 deletions
diff --git a/src/journal/journal-file.c b/src/journal/journal-file.c
index ccb689451e..52110aa498 100644
--- a/src/journal/journal-file.c
+++ b/src/journal/journal-file.c
@@ -2898,7 +2898,7 @@ fail:
if (f->fd >= 0 && mmap_cache_got_sigbus(f->mmap, f->fd))
r = -EIO;
- journal_file_close(f);
+ (void) journal_file_close(f);
return r;
}
diff --git a/src/journal/journald-server.c b/src/journal/journald-server.c
index ee2db8d29f..5e120fdac0 100644
--- a/src/journal/journald-server.c
+++ b/src/journal/journald-server.c
@@ -259,7 +259,7 @@ static int open_journal(
r = journal_file_enable_post_change_timer(f, s->event, POST_CHANGE_TIMER_INTERVAL_USEC);
if (r < 0) {
- journal_file_close(f);
+ (void) journal_file_close(f);
return r;
}
@@ -302,7 +302,7 @@ static JournalFile* find_journal(Server *s, uid_t uid) {
/* Too many open? Then let's close one */
f = ordered_hashmap_steal_first(s->user_journals);
assert(f);
- journal_file_close(f);
+ (void) journal_file_close(f);
}
r = open_journal(s, true, p, O_RDWR|O_CREAT, s->seal, &s->system_metrics, &f);
@@ -313,7 +313,7 @@ static JournalFile* find_journal(Server *s, uid_t uid) {
r = ordered_hashmap_put(s->user_journals, UID_TO_PTR(uid), f);
if (r < 0) {
- journal_file_close(f);
+ (void) journal_file_close(f);
return s->system_journal;
}
@@ -1922,13 +1922,13 @@ void server_done(Server *s) {
stdout_stream_free(s->stdout_streams);
if (s->system_journal)
- journal_file_close(s->system_journal);
+ (void) journal_file_close(s->system_journal);
if (s->runtime_journal)
- journal_file_close(s->runtime_journal);
+ (void) journal_file_close(s->runtime_journal);
while ((f = ordered_hashmap_steal_first(s->user_journals)))
- journal_file_close(f);
+ (void) journal_file_close(f);
ordered_hashmap_free(s->user_journals);
diff --git a/src/journal/sd-journal.c b/src/journal/sd-journal.c
index 5a2a28a8d4..9bc4215f2e 100644
--- a/src/journal/sd-journal.c
+++ b/src/journal/sd-journal.c
@@ -1258,7 +1258,7 @@ static int add_any_file(sd_journal *j, const char *path) {
r = ordered_hashmap_put(j->files, f->path, f);
if (r < 0) {
- journal_file_close(f);
+ (void) journal_file_close(f);
goto fail;
}
@@ -1343,7 +1343,7 @@ static void remove_file_real(sd_journal *j, JournalFile *f) {
j->fields_file_lost = true;
}
- journal_file_close(f);
+ (void) journal_file_close(f);
j->current_invalidate_counter ++;
}
@@ -1784,7 +1784,7 @@ _public_ void sd_journal_close(sd_journal *j) {
sd_journal_flush_matches(j);
while ((f = ordered_hashmap_steal_first(j->files)))
- journal_file_close(f);
+ (void) journal_file_close(f);
ordered_hashmap_free(j->files);
diff --git a/src/journal/test-journal-flush.c b/src/journal/test-journal-flush.c
index 7bd9c40366..0c35d532c6 100644
--- a/src/journal/test-journal-flush.c
+++ b/src/journal/test-journal-flush.c
@@ -66,7 +66,7 @@ int main(int argc, char *argv[]) {
sd_journal_close(j);
- journal_file_close(new_journal);
+ (void) journal_file_close(new_journal);
unlink(fn);
assert_se(rmdir(dn) == 0);
diff --git a/src/journal/test-journal-interleaving.c b/src/journal/test-journal-interleaving.c
index 7f94990888..6c6238cc4b 100644
--- a/src/journal/test-journal-interleaving.c
+++ b/src/journal/test-journal-interleaving.c
@@ -57,7 +57,7 @@ static JournalFile *test_open(const char *name) {
}
static void test_close(JournalFile *f) {
- journal_file_close (f);
+ (void) journal_file_close (f);
}
static void append_number(JournalFile *f, int n, uint64_t *seqnum) {
diff --git a/src/journal/test-journal-stream.c b/src/journal/test-journal-stream.c
index 4e6f8c0f7b..82543bb5f9 100644
--- a/src/journal/test-journal-stream.c
+++ b/src/journal/test-journal-stream.c
@@ -133,9 +133,9 @@ int main(int argc, char *argv[]) {
free(q);
}
- journal_file_close(one);
- journal_file_close(two);
- journal_file_close(three);
+ (void) journal_file_close(one);
+ (void) journal_file_close(two);
+ (void) journal_file_close(three);
assert_se(sd_journal_open_directory(&j, t, 0) >= 0);
diff --git a/src/journal/test-journal-verify.c b/src/journal/test-journal-verify.c
index a26c624f41..3fec18c480 100644
--- a/src/journal/test-journal-verify.c
+++ b/src/journal/test-journal-verify.c
@@ -60,7 +60,7 @@ static int raw_verify(const char *fn, const char *verification_key) {
return r;
r = journal_file_verify(f, verification_key, NULL, NULL, NULL, false);
- journal_file_close(f);
+ (void) journal_file_close(f);
return r;
}
@@ -107,7 +107,7 @@ int main(int argc, char *argv[]) {
free(test);
}
- journal_file_close(f);
+ (void) journal_file_close(f);
log_info("Verifying...");
@@ -123,7 +123,7 @@ int main(int argc, char *argv[]) {
format_timestamp(b, sizeof(b), to),
format_timespan(c, sizeof(c), total > to ? total - to : 0, 0));
- journal_file_close(f);
+ (void) journal_file_close(f);
if (verification_key) {
log_info("Toggling bits...");
diff --git a/src/journal/test-journal.c b/src/journal/test-journal.c
index 0334b1cd1a..94d26a2573 100644
--- a/src/journal/test-journal.c
+++ b/src/journal/test-journal.c
@@ -107,7 +107,7 @@ static void test_non_empty(void) {
journal_file_rotate(&f, true, true);
journal_file_rotate(&f, true, true);
- journal_file_close(f);
+ (void) journal_file_close(f);
log_info("Done...");
@@ -158,10 +158,10 @@ static void test_empty(void) {
assert_se(rm_rf(t, REMOVE_ROOT|REMOVE_PHYSICAL) >= 0);
}
- journal_file_close(f1);
- journal_file_close(f2);
- journal_file_close(f3);
- journal_file_close(f4);
+ (void) journal_file_close(f1);
+ (void) journal_file_close(f2);
+ (void) journal_file_close(f3);
+ (void) journal_file_close(f4);
}
int main(int argc, char *argv[]) {