Skip to content
Snippets Groups Projects
Commit 23547fa2 authored by Yang Tse's avatar Yang Tse
Browse files

sockfilt will quit when orphaned

parent 550d6f74
No related branches found
No related tags found
No related merge requests found
......@@ -2002,6 +2002,7 @@ AC_CHECK_FUNCS( strtoll \
strlcat \
getpwuid \
geteuid \
getppid \
utime \
sigsetjmp \
basename \
......
......@@ -181,6 +181,13 @@ static int juggle(curl_socket_t *sockfdp,
unsigned char buffer[17010];
char data[16];
#ifdef HAVE_GETPPID
/* As a last resort, quit if sockfilt process becomes orphan. Just in case
parent ftpserver process has died without killing its sockfilt children */
if(getppid() <= 1)
return FALSE;
#endif
timeout.tv_sec = 120;
timeout.tv_usec = 0;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment