From c26ddc568f3fb26b45a22cbf89d3294113e70377 Mon Sep 17 00:00:00 2001 From: J William Piggott Date: Sat, 15 Jul 2017 16:01:13 -0400 Subject: [PATCH] hwclock: improve RTC epoch messages Signed-off-by: J William Piggott --- sys-utils/hwclock.c | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/sys-utils/hwclock.c b/sys-utils/hwclock.c index 445d736358..423ebcd016 100644 --- a/sys-utils/hwclock.c +++ b/sys-utils/hwclock.c @@ -1172,23 +1172,17 @@ manipulate_epoch(const struct hwclock_control *ctl) unsigned long epoch; if (get_epoch_rtc(ctl, &epoch)) - warnx(_ - ("Unable to get the epoch value from the kernel.")); + warnx(_("unable to read the RTC epoch.")); else - printf(_("Kernel is assuming an epoch value of %lu\n"), - epoch); + printf(_("The RTC epoch is set to %lu.\n"), epoch); } else if (ctl->setepoch) { if (!ctl->epoch_option) - warnx(_ - ("To set the epoch value, you must use the 'epoch' " - "option to tell to what value to set it.")); + warnx(_("--epoch is required for --setepoch.")); else if (ctl->testing) - printf(_ - ("Not setting the epoch to %s - testing only.\n"), + printf(_("Test mode: epoch was not set to %s.\n"), ctl->epoch_option); else if (set_epoch_rtc(ctl)) - printf(_ - ("Unable to set the epoch value in the kernel.\n")); + warnx(_("unable to set the RTC epoch.")); } } #endif /* __linux__ __alpha__ */ -- 2.47.3