summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sys-utils/hwclock.c10
-rw-r--r--sys-utils/hwclock.h7
2 files changed, 4 insertions, 13 deletions
diff --git a/sys-utils/hwclock.c b/sys-utils/hwclock.c
index 3cc425f9d..10cb02a50 100644
--- a/sys-utils/hwclock.c
+++ b/sys-utils/hwclock.c
@@ -1912,22 +1912,18 @@ int main(int argc, char **argv)
return rc; /* Not reached */
}
-#ifdef HAVE_LIBAUDIT
-/*
- * hwclock_exit calls either this function or plain exit depending
- * HAVE_LIBAUDIT see also clock.h
- */
-void __attribute__((__noreturn__)) hwaudit_exit(int status)
+void __attribute__((__noreturn__)) hwclock_exit(int status)
{
+#ifdef HAVE_LIBAUDIT
if (hwaudit_on) {
audit_log_user_message(hwaudit_fd, AUDIT_USYS_CONFIG,
"op=change-system-time", NULL, NULL, NULL,
status ? 0 : 1);
close(hwaudit_fd);
}
+#endif
exit(status);
}
-#endif
/*
* History of this program:
diff --git a/sys-utils/hwclock.h b/sys-utils/hwclock.h
index 974d96a40..d58ebbc6f 100644
--- a/sys-utils/hwclock.h
+++ b/sys-utils/hwclock.h
@@ -35,11 +35,6 @@ extern int get_epoch_rtc(unsigned long *epoch, int silent);
extern int set_epoch_rtc(unsigned long epoch);
extern char *rtc_dev_name;
-#ifdef HAVE_LIBAUDIT
-extern void hwaudit_exit(int status);
-# define hwclock_exit(_status) hwaudit_exit(_status)
-#else
-# define hwclock_exit(_status) exit(_status)
-#endif
+extern void hwclock_exit(int status);
#endif /* HWCLOCK_CLOCK_H */