Close the file descriptor in makeReadableAndClose