Implement a potentially Windows-compatible version of FD passing while maintaining Unix compatibility