]> err.no Git - util-linux/commitdiff
fix messages in "hwclock.sh start". Closes: #436873
authorLaMont Jones <lamont@debian.org>
Mon, 1 Oct 2007 18:22:27 +0000 (12:22 -0600)
committerLaMont Jones <lamont@debian.org>
Mon, 1 Oct 2007 18:22:27 +0000 (12:22 -0600)
Signed-off-by: LaMont Jones <lamont@debian.org>
debian/hwclock.sh

index 241ec02780455525920b2aa17fe78a05f60948c9..f3ea0589647253591f1673e65bf14ee2e7ce06cc 100644 (file)
@@ -100,15 +100,17 @@ hwclocksh()
            fi
 
            if [ "$HWCLOCKACCESS" != no ]; then
-               log_action_msg "Setting the system clock."
+               log_action_msg "Setting the system clock"
 
                # Copies Hardware Clock time to System Clock using the correct
                # timezone for hardware clocks in local time, and sets kernel
                # timezone. DO NOT REMOVE.
-               /sbin/hwclock --hctosys $GMT $HWCLOCKPARS $BADYEAR $NOADJ
-
-               #       Announce the local time.
-               verbose_log_action_msg "System Clock set to: `date $UTC`"
+               if /sbin/hwclock --hctosys $GMT $HWCLOCKPARS $BADYEAR $NOADJ; then
+                   #   Announce the local time.
+                   verbose_log_action_msg "System Clock set to: `date $UTC`"
+               else
+                   log_warning_msg "Unable to set System Clock to: `date $UTC`"
+               fi
            else
                verbose_log_action_msg "Not setting System Clock"
            fi
@@ -122,7 +124,7 @@ hwclocksh()
            #          clock will not be carried across reboots.
            #
            if [ "$HWCLOCKACCESS" != no ]; then
-               log_action_msg "Saving the system clock."
+               log_action_msg "Saving the system clock"
                if [ "$GMT" = "-u" ]; then
                    GMT="--utc"
                fi