]>
Commit | Line | Data |
---|---|---|
53e1b683 | 1 | /* SPDX-License-Identifier: LGPL-2.1+ */ |
c2f1db8f | 2 | #pragma once |
86aa7ba4 LP |
3 | |
4 | /*** | |
5 | This file is part of systemd. | |
6 | ||
7 | Copyright 2012 Lennart Poettering | |
86aa7ba4 LP |
8 | ***/ |
9 | ||
10 | #include <stdbool.h> | |
a8fbdf54 TA |
11 | #include <stddef.h> |
12 | #include <stdio.h> | |
1a6c43e9 | 13 | #include <sys/types.h> |
86aa7ba4 | 14 | |
3c756001 | 15 | #include "sd-journal.h" |
81527be1 | 16 | |
a8fbdf54 | 17 | #include "macro.h" |
9bdbc2e2 | 18 | #include "output-mode.h" |
a8fbdf54 | 19 | #include "time-util.h" |
71d35b6b | 20 | #include "util.h" |
25277cd7 | 21 | |
08ace05b LP |
22 | int output_journal( |
23 | FILE *f, | |
24 | sd_journal *j, | |
25 | OutputMode mode, | |
26 | unsigned n_columns, | |
94e0bd7d | 27 | OutputFlags flags, |
cc25a67e | 28 | char **output_fields, |
b4766d5f | 29 | size_t highlight[2], |
94e0bd7d | 30 | bool *ellipsized); |
86aa7ba4 | 31 | |
b6741478 | 32 | int add_match_this_boot(sd_journal *j, const char *machine); |
5ec76417 | 33 | |
886a64fe ZJS |
34 | int add_matches_for_unit( |
35 | sd_journal *j, | |
36 | const char *unit); | |
37 | ||
38 | int add_matches_for_user_unit( | |
39 | sd_journal *j, | |
df50185b | 40 | const char *unit, |
886a64fe | 41 | uid_t uid); |
df50185b | 42 | |
886a64fe | 43 | int show_journal_by_unit( |
1a6c43e9 MT |
44 | FILE *f, |
45 | const char *unit, | |
46 | OutputMode mode, | |
47 | unsigned n_columns, | |
48 | usec_t not_before, | |
49 | unsigned how_many, | |
50 | uid_t uid, | |
886a64fe | 51 | OutputFlags flags, |
3c756001 LP |
52 | int journal_open_flags, |
53 | bool system_unit, | |
94e0bd7d | 54 | bool *ellipsized); |
1a6c43e9 | 55 | |
240a5fe8 LP |
56 | void json_escape( |
57 | FILE *f, | |
58 | const char* p, | |
59 | size_t l, | |
60 | OutputFlags flags); |