diff options
author | Yu Watanabe <watanabe.yu+github@gmail.com> | 2024-01-02 20:28:08 +0100 |
---|---|---|
committer | Yu Watanabe <watanabe.yu+github@gmail.com> | 2024-02-11 18:42:36 +0100 |
commit | f7f062bf9f194dc14a4ffc6e7fff9d8bfdea2147 (patch) | |
tree | 32fce8736d50d97566cb71cc5828488629069944 /src/journal-remote | |
parent | sd-journal: introduce SD_JOURNAL_ASSUME_IMMUTABLE flag (diff) | |
download | systemd-f7f062bf9f194dc14a4ffc6e7fff9d8bfdea2147.tar.xz systemd-f7f062bf9f194dc14a4ffc6e7fff9d8bfdea2147.zip |
tree-wide: set SD_JOURNAL_ASSUME_IMMUTABLE where appropriate
Co-authored-by: Costa Tsaousis <costa@netdata.cloud>
Diffstat (limited to 'src/journal-remote')
-rw-r--r-- | src/journal-remote/fuzz-journal-remote.c | 2 | ||||
-rw-r--r-- | src/journal-remote/journal-upload.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/journal-remote/fuzz-journal-remote.c b/src/journal-remote/fuzz-journal-remote.c index 557100bb96..774389dee3 100644 --- a/src/journal-remote/fuzz-journal-remote.c +++ b/src/journal-remote/fuzz-journal-remote.c @@ -67,7 +67,7 @@ int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) { /* Out */ - r = sd_journal_open_files(&j, (const char**) STRV_MAKE(name), 0); + r = sd_journal_open_files(&j, (const char**) STRV_MAKE(name), SD_JOURNAL_ASSUME_IMMUTABLE); if (r < 0) { log_error_errno(r, "sd_journal_open_files([\"%s\"]) failed: %m", name); assert_se(IN_SET(r, -ENOMEM, -EMFILE, -ENFILE, -ENODATA)); diff --git a/src/journal-remote/journal-upload.c b/src/journal-remote/journal-upload.c index db74355842..97b5f929ab 100644 --- a/src/journal-remote/journal-upload.c +++ b/src/journal-remote/journal-upload.c @@ -777,7 +777,7 @@ static int open_journal(sd_journal **j) { else if (arg_file) r = sd_journal_open_files(j, (const char**) arg_file, 0); else if (arg_machine) - r = journal_open_machine(j, arg_machine); + r = journal_open_machine(j, arg_machine, 0); else r = sd_journal_open_namespace(j, arg_namespace, (arg_merge ? 0 : SD_JOURNAL_LOCAL_ONLY) | arg_namespace_flags | arg_journal_type); |