man: document signal unsafeness of journal functions

Fixes #7912.
This commit is contained in:
Zbigniew Jędrzejewski-Szmek 2018-01-20 14:23:54 +11:00
parent 000b1ba561
commit 89f552c0e2
1 changed files with 14 additions and 0 deletions

View File

@ -230,6 +230,20 @@ else {
journal.</para>
</refsect1>
<refsect1>
<title>Signal safety</title>
<para>In general, <function>sd_journal_get_fd()</function>,
<function>sd_journal_get_events()</function>, and <function>sd_journal_get_timeout()</function>
are <emphasis>not</emphasis> "async signal safe" in the meaning of
<citerefentry project='man-pages'><refentrytitle>signal</refentrytitle><manvolnum>7</manvolnum></citerefentry>.
Nevertheless, only the first call to any of those three functions performs unsafe operations, so
subsequent calls <emphasis>are</emphasis> safe.</para>
<para><function>sd_journal_process()</function> and <function>sd_journal_wait()</function> are not
safe. <function>sd_journal_reliable_fd()</function> is safe.</para>
</refsect1>
<refsect1>
<title>Notes</title>