open FH, "<&=".$fd or die "Can't fdopen $fd: $!\n";