From 047744cc50cdc2c84cc15374fa87a194ef63d384 Mon Sep 17 00:00:00 2001 From: Leah Neukirchen Date: Fri, 6 Sep 2019 11:19:26 +0200 Subject: halt: style --- halt.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/halt.c b/halt.c index 67a11a1..7bb4d35 100644 --- a/halt.c +++ b/halt.c @@ -38,13 +38,13 @@ void write_wtmp(int boot) { utmp.ut_type = boot ? BOOT_TIME : RUN_LVL; - strncpy(utmp.ut_name, boot ? "reboot" : "shutdown", sizeof(utmp.ut_name)); - strncpy(utmp.ut_id , "~~", sizeof(utmp.ut_id)); - strncpy(utmp.ut_line, boot ? "~" : "~~", sizeof(utmp.ut_line)); + strncpy(utmp.ut_name, boot ? "reboot" : "shutdown", sizeof utmp.ut_name); + strncpy(utmp.ut_id , "~~", sizeof utmp.ut_id); + strncpy(utmp.ut_line, boot ? "~" : "~~", sizeof utmp.ut_line); if (uname(&uname_buf) == 0) - strncpy(utmp.ut_host, uname_buf.release, sizeof(utmp.ut_host)); + strncpy(utmp.ut_host, uname_buf.release, sizeof utmp.ut_host); - write(fd, (char *)&utmp, sizeof(utmp)); + write(fd, (char *)&utmp, sizeof utmp); close(fd); if (boot) { -- cgit 1.4.1