← Commit list

c8685ead5

Robert Griebl
Robert Griebl
2004-03-21
FAILED Duration: 91s

Subject

The utc variable was not modified according to the -u/-l command line parameters.

Binary

No binary (build failed)

Architecture & Compiler Flags

Architecture: x86_64-linux-gnu Compiler: gcc (Ubuntu 11.4.0-1ubuntu1~22.04.3) 11.4.0

—

Build Log

(log yok)

Commit Diff GitHub →

util-linux/hwclock.c+8 -2
@@ -213,10 +213,16 @@ static const struct option hwclock_long_options[] = {
}
/* If -u or -l wasnt give check if we are using utc */
- if ((opt & (HWCLOCK_OPT_UTC | HWCLOCK_OPT_LOCALTIME)) == 0) {
+ if (opt & HWCLOCK_OPT_UTC) {
+ utc = 1;
+ }
+ else if (opt & HWCLOCK_OPT_LOCALTIME) {
+ utc = 0;
+ }
+ else {
utc = check_utc();
}
-
+
if (opt & HWCLOCK_OPT_HCTOSYS) {
return to_sys_clock ( utc );
}