diff3: plug fd leak

MFC After:	1 week
Reported by:	kib

(cherry picked from commit 33424fd50ee0333bc6f70b5b14a270b85e5b5de1)
This commit is contained in:
Baptiste Daroussin 2026-03-26 08:40:29 +01:00
parent 8cc85a8751
commit 2abaf8acd5

View file

@ -947,6 +947,7 @@ wait_and_check(int pd)
if (errno != EINTR)
err(2, "pdwait");
}
close(pd);
if (WIFEXITED(status) && WEXITSTATUS(status) >= 2)
errx(2, "diff exited abnormally");