Use fork instead of vfork since setenv clobber parent environment
Fork already used for INTERNAL_LS in anycase
This commit is contained in:
parent
46589cb624
commit
f85f9e5656
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=36070
@ -39,7 +39,7 @@
|
||||
static char sccsid[] = "@(#)popen.c 8.3 (Berkeley) 4/6/94";
|
||||
#endif
|
||||
static const char rcsid[] =
|
||||
"$Id: popen.c,v 1.11 1998/04/27 10:51:26 dg Exp $";
|
||||
"$Id: popen.c,v 1.12 1998/05/15 16:08:52 ache Exp $";
|
||||
#endif /* not lint */
|
||||
|
||||
#include <sys/types.h>
|
||||
@ -120,10 +120,8 @@ ftpd_popen(program, type)
|
||||
iop = NULL;
|
||||
#ifdef INTERNAL_LS
|
||||
fflush(NULL);
|
||||
pid = (strcmp(gargv[0], _PATH_LS) == 0) ? fork() : vfork();
|
||||
#else
|
||||
pid = vfork();
|
||||
#endif
|
||||
pid = fork();
|
||||
switch(pid) {
|
||||
case -1: /* error */
|
||||
(void)close(pdes[0]);
|
||||
|
Loading…
Reference in New Issue
Block a user