Display more meaningful time in session list

Due to the stale session detection logic we will always access
the socket thus essentially printing the current time which
does not seem useful.
This commit is contained in:
Marc André Tanner 2015-08-07 17:00:16 +02:00
parent e08d7acc3a
commit 57e7acba69
1 changed files with 1 additions and 1 deletions

View File

@ -553,7 +553,7 @@ static int list_session(void) {
while (n--) {
struct stat sb; char buf[255];
if (stat(namelist[n]->d_name, &sb) == 0 && S_ISSOCK(sb.st_mode)) {
strftime(buf, sizeof(buf), "%a%t %F %T", localtime(&sb.st_atime));
strftime(buf, sizeof(buf), "%a%t %F %T", localtime(&sb.st_mtime));
char status = ' ';
char *local = strstr(namelist[n]->d_name, server.host);
if (local) {