summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorColin Walters <walters@verbum.org>2023-04-10 16:22:25 -0400
committerYu Watanabe <watanabe.yu+github@gmail.com>2023-04-11 12:36:53 +0900
commit4e1ac54e1c38682d5435a0cf1a9a1bfdcaa8e3f2 (patch)
tree6940d89fa9b29aa8778ba1c44267a5ae5639681c /src
parent2653ded4d1c191c671d6aed51821dd976f2c9712 (diff)
downloadsystemd-4e1ac54e1c38682d5435a0cf1a9a1bfdcaa8e3f2.tar.gz
tree-wide: A few more uses of "unmet" for conditions
This is a followup to 413e8650b71d4404a7453403797f93d73d88c466 > tree-wide: Use "unmet" for condition checks, not "failed" Since I noticed when running `systemctl status` on a recent systemd still seeing `Condition: start condition failed` To recap the original rationale here for "unmet" is that it's normal for some units to be conditional, so the term "failure" here is too strong.
Diffstat (limited to 'src')
-rw-r--r--src/core/unit.c4
-rw-r--r--src/systemctl/systemctl-show.c2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/core/unit.c b/src/core/unit.c
index 846d15b415..409801aed2 100644
--- a/src/core/unit.c
+++ b/src/core/unit.c
@@ -1890,12 +1890,12 @@ int unit_start(Unit *u, ActivationDetails *details) {
if (UNIT_VTABLE(u)->once_only && dual_timestamp_is_set(&u->inactive_enter_timestamp))
return -ESTALE;
- /* If the conditions failed, don't do anything at all. If we already are activating this call might
+ /* If the conditions were unmet, don't do anything at all. If we already are activating this call might
* still be useful to speed up activation in case there is some hold-off time, but we don't want to
* recheck the condition in that case. */
if (state != UNIT_ACTIVATING &&
!unit_test_condition(u))
- return log_unit_debug_errno(u, SYNTHETIC_ERRNO(ECOMM), "Starting requested but condition failed. Not starting unit.");
+ return log_unit_debug_errno(u, SYNTHETIC_ERRNO(ECOMM), "Starting requested but condition not met. Not starting unit.");
/* If the asserts failed, fail the entire job */
if (state != UNIT_ACTIVATING &&
diff --git a/src/systemctl/systemctl-show.c b/src/systemctl/systemctl-show.c
index 4a14c105dd..6422550af4 100644
--- a/src/systemctl/systemctl-show.c
+++ b/src/systemctl/systemctl-show.c
@@ -516,7 +516,7 @@ static void print_status_info(
if (!i->condition_result && i->condition_timestamp > 0) {
int n = 0;
- printf(" Condition: start %scondition failed%s at %s; %s\n",
+ printf(" Condition: start %scondition unmet%s at %s; %s\n",
ansi_highlight_yellow(), ansi_normal(),
FORMAT_TIMESTAMP_STYLE(i->condition_timestamp, arg_timestamp_style),
FORMAT_TIMESTAMP_RELATIVE(i->condition_timestamp));