Is it possible to get the filename of a file descriptor (Linux) in C?
In Windows, with GetFileInformationByHandleEx, passing FileNameInfo, you can retrieve the file name.