ITS#10355 lmdb mplay: don't assign to stdin/stdout

This commit is contained in:
Howard Chu 2025-06-12 15:16:00 +01:00
parent c85bcff9c5
commit 7c7988003b

View file

@ -483,12 +483,10 @@ static pidpair *addpid(int tpid)
pipe(fdin);
if ((pid = fork()) == 0) {
/* child */
fclose(stdin);
fclose(stdout);
fflush(stdin);
fflush(stdout);
dup2(fdout[0], 0);
dup2(fdin[1], 1);
stdin = fdopen(0, "r");
stdout = fdopen(1, "w");
child();
return 0; /* NOTREACHED */
} else {