]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
hwclock: improve RTC epoch messages
authorJ William Piggott <elseifthen@gmx.com>
Sat, 15 Jul 2017 20:01:13 +0000 (16:01 -0400)
committerJ William Piggott <elseifthen@gmx.com>
Sun, 16 Jul 2017 12:41:54 +0000 (08:41 -0400)
Signed-off-by: J William Piggott <elseifthen@gmx.com>
sys-utils/hwclock.c

index 445d736358586cdafdf82e1b95db863a13d554f3..423ebcd016401ea72586523b17bc8e8237fb2e93 100644 (file)
@@ -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__ */