// #if defined (__CYGWIN__) || !defined(HAVE_FORK)
// if (fptr->finalize == pipe_finalize)
// pipe_add_fptr(fptr);
// #endif
fd = fptr.fd();
fd2 = orig.fd();
if (fd != fd2) {
if (fptr.IS_PREP_STDIO() || fd.bestFileno() <= 2 || fptr.stdio_file == null) {
/* need to keep FILE objects of stdin, stdout and stderr */
checkReopenCloexecDup2(runtime, orig, fd2, fd);