summaryrefslogtreecommitdiffstats
path: root/login-utils/last.c
diff options
context:
space:
mode:
authorSami Kerola2013-08-28 16:37:46 +0200
committerSami Kerola2013-08-29 19:14:09 +0200
commit438269dca9d8b099fee4c8db4904ffb926d45f99 (patch)
tree6a7a99638cb75bdb96115bdc28b2e0021fd77f87 /login-utils/last.c
parentdocs: add --time-format to last(1) manual page (diff)
downloadkernel-qcow2-util-linux-438269dca9d8b099fee4c8db4904ffb926d45f99.tar.gz
kernel-qcow2-util-linux-438269dca9d8b099fee4c8db4904ffb926d45f99.tar.xz
kernel-qcow2-util-linux-438269dca9d8b099fee4c8db4904ffb926d45f99.zip
last: never restrict session time
When a session time will reach whopping 10000 days the last round bracket is unnecessarily removed from output. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Diffstat (limited to 'login-utils/last.c')
-rw-r--r--login-utils/last.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/login-utils/last.c b/login-utils/last.c
index 93dc8d40e..dd0ca4912 100644
--- a/login-utils/last.c
+++ b/login-utils/last.c
@@ -462,7 +462,7 @@ static int list(const struct last_control *ctl, struct utmp *p, time_t t, int wh
if (ctl->showhost) {
if (!ctl->altlist) {
len = snprintf(final, sizeof(final),
- "%-8.*s %-12.12s %-16.*s %-*.*s %-*.*s %-12.12s\n",
+ "%-8.*s %-12.12s %-16.*s %-*.*s %-*.*s %s\n",
ctl->name_len, p->ut_name, utline,
ctl->domain_len, domain,
tftl[ctl->time_fmt].in, tftl[ctl->time_fmt].in, logintime,
@@ -478,7 +478,7 @@ static int list(const struct last_control *ctl, struct utmp *p, time_t t, int wh
}
} else
len = snprintf(final, sizeof(final),
- "%-8.*s %-12.12s %-*.*s %-*.*s %-12.12s\n",
+ "%-8.*s %-12.12s %-*.*s %-*.*s %s\n",
ctl->name_len, p->ut_name, utline,
tftl[ctl->time_fmt].in, tftl[ctl->time_fmt].in, logintime,
tftl[ctl->time_fmt].out, tftl[ctl->time_fmt].out, logouttime,