From: Craig Small Date: Mon, 7 Sep 2015 08:38:39 +0000 (+1000) Subject: library: Add space after days for uptime X-Git-Tag: v4.0.0~1040 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=617a4d0f7007499a6d9d06aa4dafd34f55890fc1;p=procps-ng library: Add space after days for uptime Uptime output for both w and uptime command were showing no comma or space after days. $ ./uptime 18:32:21 up 22 days7 min, 6 users, load average: 0.23, 0.46, 0.64 Minor tweak to fix this. --- diff --git a/proc/uptime.c b/proc/uptime.c index ca571b9d..e6412052 100644 --- a/proc/uptime.c +++ b/proc/uptime.c @@ -125,7 +125,7 @@ PROCPS_EXPORT char *procps_uptime_sprint(void) realtime->tm_hour, realtime->tm_min, realtime->tm_sec); if (updays) - pos += sprintf(upbuf + pos, "%d %s", updays, (updays > 1) ? "days" : "day"); + pos += sprintf(upbuf + pos, "%d %s, ", updays, (updays > 1) ? "days" : "day"); if (uphours) pos += sprintf(upbuf + pos, "%2d:%02d, ", uphours, upminutes);