ps: conditionally enable -T on non-DESKTOP build too
[oweals/busybox.git] / miscutils / last.c
index 612f50488228c7d04410221e1c4081ecda7b82a8..f8c301395de14cd961fc22ce330a71f06697e0eb 100644 (file)
@@ -35,7 +35,7 @@
 #endif
 
 int last_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
-int last_main(int argc, char **argv ATTRIBUTE_UNUSED)
+int last_main(int argc, char **argv UNUSED_PARAM)
 {
        struct utmp ut;
        int n, file = STDIN_FILENO;
@@ -117,6 +117,8 @@ int last_main(int argc, char **argv ATTRIBUTE_UNUSED)
                                        strcpy(ut.ut_line, "system boot");
                        }
                }
+               /* manpages say ut_tv.tv_sec *is* time_t,
+                * but some systems have it wrong */
                t_tmp = (time_t)ut.ut_tv.tv_sec;
                printf("%-10s %-14s %-18s %-12.12s\n",
                       ut.ut_user, ut.ut_line, ut.ut_host, ctime(&t_tmp) + 4);