Talk hanging under 4.2bsd
Steven Law
sml at mulga.OZ
Fri Jun 1 05:39:11 AEST 1984
[]
If your 'talk' works when you specify the terminal i.e.
'talk uid ttyxx', then the following bug fix should work for you.
In the file get_names.c it sets his_tty to (char *)0
if you don't give a tty number. Later it copies TTY_SIZE chars
from there into the request structure. On our system it copies
garbage. The following diff gives the simple fix:
diff get_names.c get_names.c.bad
101,105c101,102
< if (his_tty) {
< strncpy(msg.r_tty, his_tty, TTY_SIZE);
< msg.r_tty[TTY_SIZE - 1] = '\0';
< } else
< msg.r_tty[0] = '\0';
---
> strncpy(msg.r_tty, his_tty, TTY_SIZE);
> msg.r_tty[TTY_SIZE - 1] = '\0';
-----
" 'Twas Mulga Bill from Eaglehawk, that caught the cycling craze."
Steven Law.
decvax!mulga!sml
More information about the Comp.bugs.4bsd.ucb-fixes
mailing list