mirror of
https://github.com/debauchee/barrier.git
synced 2026-02-09 13:15:33 +08:00
This fixes #976, fixes #974, fixes #444. On Windows the standard stream open() functions expect bytes encoded in current system encoding, not UTF8. Since we're dealing with UTF8 throughout the application this results in wrong paths being passed and failure to open files. As a solution, we convert the paths to UTF16 via the WCHAR character type and use the special Windows-specific overloads of open() functions.