In the "Message from Talk_Daemon" announcement, print the date as well

as the current time.  It's nice to know whether the talk request you
see was sent just a few minutes ago (assuming you didn't hear the
bell), or if it's been decaying for days (weeks?).
This commit is contained in:
Dima Dorfman 2001-06-07 05:26:57 +00:00
parent 889b293a21
commit 4513fdec5e
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=77862

View File

@ -125,8 +125,10 @@ print_mesg(tty, tf, request, remote_machine)
max_size = max(max_size, sizes[i]);
i++;
(void)snprintf(line_buf[i], N_CHARS,
"Message from Talk_Daemon@%s at %d:%02d ...",
hostname, localclock->tm_hour , localclock->tm_min );
"Message from Talk_Daemon@%s at %d:%02d on %d/%.2d/%.2d ...",
hostname, localclock->tm_hour , localclock->tm_min,
localclock->tm_year + 1900, localclock->tm_mon,
localclock->tm_mday);
sizes[i] = strlen(line_buf[i]);
max_size = max(max_size, sizes[i]);
i++;