1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-24 11:29:10 +00:00

Don't use non-signal-safe functions (exit(3) in this case) in

signal handlers.  In this case, use _exit(2) instead, following
the call to shutdown(2).

This fixes rare telnetd hangs.

PR:		misc/33672
Submitted by:	Umesh Krishnaswamy <umesh@juniper.net>
MFC after:	1 month
This commit is contained in:
Sheldon Hearn 2002-02-05 15:20:02 +00:00
parent cc9f4eb939
commit fa3e900453
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=90242
3 changed files with 3 additions and 3 deletions

View File

@ -1327,5 +1327,5 @@ cleanup(int sig __unused)
(void)chmod(line, 0666);
(void)chown(line, 0, 0);
(void) shutdown(net, 2);
exit(1);
_exit(1);
}

View File

@ -1327,5 +1327,5 @@ cleanup(int sig __unused)
(void)chmod(line, 0666);
(void)chown(line, 0, 0);
(void) shutdown(net, 2);
exit(1);
_exit(1);
}

View File

@ -1180,5 +1180,5 @@ cleanup(int sig __unused)
(void)chmod(line, 0666);
(void)chown(line, 0, 0);
(void) shutdown(net, 2);
exit(1);
_exit(1);
}