]> git.ipfire.org Git - thirdparty/util-linux.git/commit
hwclock: move command-line options to control structure
authorSami Kerola <kerolasa@iki.fi>
Sat, 16 Jul 2016 15:45:07 +0000 (16:45 +0100)
committerSami Kerola <kerolasa@iki.fi>
Sat, 4 Feb 2017 23:39:37 +0000 (23:39 +0000)
commit336f7c5f684be96b4908cd3f02226964ed302e63
treed1de0ec622de82419f6092f6badfdbc9bf8d35e0
parentb68e1f44ab8ac5bd96d7f9222f570b60c116e25a
hwclock: move command-line options to control structure

The control structure is read-only everywhere else but in main().  Almost
all changes are about how variables are referred, with one exception.  Calls
to read_adjtime() from manipulate_clock() and compare_clock() are moved to
main().  This way it is possible to keep variable that tells if hwclock is
using UTC-0 be part of control structure.

Changes within #ifdef __alpha__ segments were tested by flipping the
preprocessor directivive otherway around and getting good compilaton all the
way to the point where linking on none-alpha system failed.

Reviewed-by: J William Piggott <elseifthen@gmx.com>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
sys-utils/hwclock-cmos.c
sys-utils/hwclock-rtc.c
sys-utils/hwclock.c
sys-utils/hwclock.h