summaryrefslogtreecommitdiff
path: root/coreutils
diff options
context:
space:
mode:
authorLadislav Michl <ladis@linux-mips.org>2023-06-14 16:35:06 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2025-07-30 19:44:39 +0200
commit427f80873274c9e4d3860a193e6f1e82b0f61997 (patch)
tree2f75d960b5d7ad032a1a8df163ed44b624214a6c /coreutils
parent65deb9f7dd23b2108655e6c7cb597defbce8a7ed (diff)
date: return failure exit code on clock_settime error
Signed-off-by: Ladislav Michl <ladis@linux-mips.org> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'coreutils')
-rw-r--r--coreutils/date.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/coreutils/date.c b/coreutils/date.c
index 3a89b6caf..ef482af1b 100644
--- a/coreutils/date.c
+++ b/coreutils/date.c
@@ -289,7 +289,7 @@ int date_main(int argc UNUSED_PARAM, char **argv)
/* if setting time, set it */
if ((opt & OPT_SET) && clock_settime(CLOCK_REALTIME, &ts) < 0) {
- bb_simple_perror_msg("can't set date");
+ bb_simple_perror_msg_and_die("can't set date");
}
}