1
0
mirror of https://github.com/systemd/systemd.git synced 2025-01-12 13:18:14 +03:00

Merge pull request #25779 from bluca/journa_remote_vacuum

journal-remote: follow-ups for #25076
This commit is contained in:
Yu Watanabe 2022-12-19 09:44:04 +09:00 committed by GitHub
commit cc3254c446
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View File

@ -1148,7 +1148,7 @@ static int run(int argc, char **argv) {
journal_reset_metrics(&s.metrics);
s.metrics.max_use = arg_max_use;
s.metrics.max_size = arg_max_size;
s.metrics.max_size = arg_keep_free;
s.metrics.keep_free = arg_keep_free;
s.metrics.n_max_files = arg_n_max_files;
r = create_remoteserver(&s, key, cert, trust);

View File

@ -22,7 +22,7 @@ static int do_rotate(ManagedJournalFile **f, MMapCache *m, JournalFileFlags file
}
Writer* writer_new(RemoteServer *server) {
Writer *w;
_cleanup_(writer_unrefp) Writer *w = NULL;
int r;
w = new0(Writer, 1);
@ -33,7 +33,7 @@ Writer* writer_new(RemoteServer *server) {
w->mmap = mmap_cache_new();
if (!w->mmap)
return mfree(w);
return NULL;
w->n_ref = 1;
w->server = server;
@ -50,7 +50,7 @@ Writer* writer_new(RemoteServer *server) {
}
}
return w;
return TAKE_PTR(w);
}
static Writer* writer_free(Writer *w) {