generateRandomFileName won't use file descriptors anymore