Remove `dead code' from rlogind.
- It shouldn't call logwtmp(). Applications like login(1) already make sure both login and logout entries are written to the storage. - There's no need to restore permissions on the pseudo-terminal, since it should be garbage collected by the kernel.
This commit is contained in:
parent
b5810e9449
commit
426f89600c
@ -479,18 +479,7 @@ protocol(int f, int p)
|
||||
void
|
||||
cleanup(int signo)
|
||||
{
|
||||
char *p;
|
||||
|
||||
p = line + sizeof(_PATH_DEV) - 1;
|
||||
if (logout(p))
|
||||
logwtmp(p, "", "");
|
||||
(void)chflags(line, 0);
|
||||
(void)chmod(line, 0666);
|
||||
(void)chown(line, 0, 0);
|
||||
*p = 'p';
|
||||
(void)chflags(line, 0);
|
||||
(void)chmod(line, 0666);
|
||||
(void)chown(line, 0, 0);
|
||||
shutdown(netf, SHUT_RDWR);
|
||||
exit(1);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user