]>
Commit | Line | Data |
---|---|---|
39fd5b08 | 1 | <?xml version='1.0'?> <!--*-nxml-*--> |
3a54a157 | 2 | <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" |
39fd5b08 JS |
3 | "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"> |
4 | ||
5 | <!-- | |
572eb058 ZJS |
6 | SPDX-License-Identifier: LGPL-2.1+ |
7 | ||
96b2fb93 | 8 | Copyright © 2016 Jan Synáček |
39fd5b08 JS |
9 | --> |
10 | ||
7d6b2723 | 11 | <refentry id="sd_journal_has_runtime_files" xmlns:xi="http://www.w3.org/2001/XInclude"> |
39fd5b08 JS |
12 | |
13 | <refentryinfo> | |
14 | <title>sd_journal_has_runtime_files</title> | |
15 | <productname>systemd</productname> | |
39fd5b08 JS |
16 | </refentryinfo> |
17 | ||
18 | <refmeta> | |
19 | <refentrytitle>sd_journal_has_runtime_files</refentrytitle> | |
20 | <manvolnum>3</manvolnum> | |
21 | </refmeta> | |
22 | ||
23 | <refnamediv> | |
24 | <refname>sd_journal_has_runtime_files</refname> | |
25 | <refname>sd_journal_has_persistent_files</refname> | |
26 | <refpurpose>Query availability of runtime or persistent journal files.</refpurpose> | |
27 | </refnamediv> | |
28 | ||
29 | <refsynopsisdiv> | |
30 | <funcsynopsis> | |
31 | <funcsynopsisinfo>#include <systemd/sd-journal.h></funcsynopsisinfo> | |
32 | ||
33 | <funcprototype> | |
34 | <funcdef>int <function>sd_journal_has_runtime_files</function></funcdef> | |
35 | <paramdef>sd_journal *<parameter>j</parameter></paramdef> | |
36 | </funcprototype> | |
37 | ||
38 | <funcprototype> | |
39 | <funcdef>int <function>sd_journal_has_persistent_files</function></funcdef> | |
40 | <paramdef>sd_journal *<parameter>j</parameter></paramdef> | |
41 | </funcprototype> | |
42 | ||
43 | </funcsynopsis> | |
44 | </refsynopsisdiv> | |
45 | ||
46 | <refsect1> | |
47 | <title>Description</title> | |
48 | ||
49 | <para><function>sd_journal_has_runtime_files()</function> returns a positive value | |
50 | if runtime journal files (present in /run/systemd/journal/) have been found. | |
51 | Otherwise returns 0.</para> | |
52 | ||
53 | <para><function>sd_journal_has_persistent_files()</function> returns a positive value | |
54 | if persistent journal files (present in /var/log/journal/) have been found. | |
55 | Otherwise returns 0.</para> | |
56 | </refsect1> | |
57 | ||
58 | <refsect1> | |
59 | <title>Return value</title> | |
60 | <para>Both <function>sd_journal_has_runtime_files()</function> | |
61 | and <function>sd_journal_has_persistent_files()</function> return -EINVAL | |
62 | if their argument is NULL. | |
63 | </para> | |
64 | </refsect1> | |
65 | ||
a8d46a16 ZJS |
66 | <refsect1> |
67 | <title>Notes</title> | |
68 | ||
64a7ef8b | 69 | <xi:include href="threads-aware.xml" xpointer="strict"/> |
a8d46a16 | 70 | |
7d6b2723 | 71 | <xi:include href="libsystemd-pkgconfig.xml" xpointer="pkgconfig-text"/> |
a8d46a16 ZJS |
72 | </refsect1> |
73 | ||
39fd5b08 JS |
74 | <refsect1> |
75 | <title>See Also</title> | |
76 | <para> | |
77 | <citerefentry><refentrytitle>sd-journal</refentrytitle><manvolnum>3</manvolnum></citerefentry> | |
78 | </para> | |
79 | </refsect1> | |
80 | ||
81 | </refentry> |