summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJouke Witteveen <j.witteveen@gmail.com>2016-12-06 13:01:35 +0100
committerJouke Witteveen <j.witteveen@gmail.com>2016-12-06 13:37:14 +0100
commita4e26faf33a255cc26d62836ca0f59b6a1e31526 (patch)
treedb2aa675c9a6b3658ac1a77d45a4268d2fa67295
parent9c77d1079dd905b90e488082a92764fcc14833e2 (diff)
man: fix $SERVICE_RESULT/$EXIT_CODE/$EXIT_STATUS documentation
Note that any exit code is available through $EXIT_STATUS and not through $EXIT_CODE. This mimics siginfo.
-rw-r--r--man/systemd.exec.xml15
-rw-r--r--src/core/service.h2
2 files changed, 14 insertions, 3 deletions
diff --git a/man/systemd.exec.xml b/man/systemd.exec.xml
index ab83876eba..f27e4a5c04 100644
--- a/man/systemd.exec.xml
+++ b/man/systemd.exec.xml
@@ -1806,23 +1806,32 @@
<title>Summary of possible service result variable values</title>
<tgroup cols='3'>
<colspec colname='result' />
- <colspec colname='status' />
<colspec colname='code' />
+ <colspec colname='status' />
<thead>
<row>
<entry><varname>$SERVICE_RESULT</varname></entry>
- <entry><varname>$EXIT_STATUS</varname></entry>
<entry><varname>$EXIT_CODE</varname></entry>
+ <entry><varname>$EXIT_STATUS</varname></entry>
</row>
</thead>
<tbody>
<row>
+ <entry morerows="1" valign="top"><literal>protocol</literal></entry>
+ <entry valign="top">not set</entry>
+ <entry>not set</entry>
+ </row>
+ <row>
+ <entry><literal>exited</literal></entry>
+ <entry><literal>0</literal></entry>
+ </row>
+
+ <row>
<entry morerows="1" valign="top"><literal>timeout</literal></entry>
<entry valign="top"><literal>killed</literal></entry>
<entry><literal>TERM</literal>, <literal>KILL</literal></entry>
</row>
-
<row>
<entry valign="top"><literal>exited</literal></entry>
<entry><literal>0</literal>, <literal>1</literal>, <literal>2</literal>, <literal
diff --git a/src/core/service.h b/src/core/service.h
index e09722a952..ff9cfaeb88 100644
--- a/src/core/service.h
+++ b/src/core/service.h
@@ -79,6 +79,8 @@ typedef enum NotifyState {
_NOTIFY_STATE_INVALID = -1
} NotifyState;
+/* The values of this enum are referenced in man/systemd.exec.xml and src/shared/bus-unit-util.c.
+ * Update those sources for each change to this enum. */
typedef enum ServiceResult {
SERVICE_SUCCESS,
SERVICE_FAILURE_RESOURCES, /* a bit of a misnomer, just our catch-all error for errnos we didn't expect */