当前位置: 动力学知识库 > 问答 > 编程问答 >

c++ - fopen_s won't open some path with accents?

问题描述:

I can't open a file with name containing accents using fopen_s.

The name of the file is stored inside a char* (example: Lgendes.txt") and I just do that:

fopen_s(&pFile, path, "rb")

It works for a file without accents but returns ENOENT for file names with them.

In fact the actual file name is "Lgendes.txt" and I don't have control on that because it is produced by the library I have no control over...

I tried with wfopen_s and wchar* with the same result.

Also, another library is able to open the file by using the filename I stored.

分享给朋友:
您可能感兴趣的文章:
随机阅读: