mirror of
https://git.FreeBSD.org/src.git
synced 2024-10-20 02:38:43 +00:00
vfork -> fork. This home made popen() had the same bug as the library
popen(), but worse. The child calls execvp(), which calls malloc() a bit more than execl(), and it calls non-library functions that call malloc() and who-knows-what else (stdio is called in at least some error cases).
This commit is contained in:
parent
4689d219ff
commit
db6b691087
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=40188
@ -231,7 +231,7 @@ start_command(cmd, mask, infd, outfd, a0, a1, a2)
|
||||
{
|
||||
int pid;
|
||||
|
||||
if ((pid = vfork()) < 0) {
|
||||
if ((pid = fork()) < 0) {
|
||||
perror("fork");
|
||||
return -1;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user