summaryrefslogtreecommitdiff
path: root/src/journal-remote/journal-remote-write.h
diff options
context:
space:
mode:
authorYu Watanabe <watanabe.yu+github@gmail.com>2023-03-28 02:26:33 +0900
committerYu Watanabe <watanabe.yu+github@gmail.com>2023-03-28 02:26:33 +0900
commit4c3d2523a0ec8a075652d8b8a80787747576e03f (patch)
treea03bf0bfdfe05dbc3e193752d2faced343947ca4 /src/journal-remote/journal-remote-write.h
parenta065dcd239e9219112ad131aa3cef060a666b377 (diff)
downloadsystemd-4c3d2523a0ec8a075652d8b8a80787747576e03f.tar.gz
journal-remote: make writer_new() return negative errno on failure
After f12b399dd6362a03379cb769954ebfb9972236ed, writer_new() may fail with non-OOM error. Let's return the error cause, and logs the failure in the caller side. This also drops logs in journal_remote_get_writer(), adds its caller typically logs the failure.
Diffstat (limited to 'src/journal-remote/journal-remote-write.h')
-rw-r--r--src/journal-remote/journal-remote-write.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/journal-remote/journal-remote-write.h b/src/journal-remote/journal-remote-write.h
index c140f6cba3..55513d9bf7 100644
--- a/src/journal-remote/journal-remote-write.h
+++ b/src/journal-remote/journal-remote-write.h
@@ -20,7 +20,7 @@ typedef struct Writer {
unsigned n_ref;
} Writer;
-Writer* writer_new(RemoteServer* server);
+int writer_new(RemoteServer *server, Writer **ret);
Writer* writer_ref(Writer *w);
Writer* writer_unref(Writer *w);