Cygwin: pipes: always close read side pipe handle in error case

Add missing CloseHandle.

Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
This commit is contained in:
Corinna Vinschen 2021-09-03 10:25:29 +02:00
parent 464f7145f6
commit b12cf6b3cf
1 changed files with 1 additions and 0 deletions

View File

@ -608,6 +608,7 @@ fhandler_pipe::create (fhandler_pipe *fhs[2], unsigned psize, int mode)
else if ((fhs[1] = (fhandler_pipe *) build_fh_dev (*pipew_dev)) == NULL)
{
delete fhs[0];
CloseHandle (r);
CloseHandle (w);
}
else