Skip to content

Use Unicode Windows APIs for UTF-8 filesystem paths #525

Closed

Description

@LunaStev

Wave source strings can contain UTF-8 names, while the Windows filesystem provider passes their bytes directly to CreateFileA and other narrow path APIs. There is no UTF-8/UTF-16 conversion. On a Windows configuration whose narrow API code page differs from UTF-8, non-ASCII filenames can be misinterpreted or fail to resolve. The same mismatch affects returned current-directory bytes.

Source evidence at the head of #520:

Acceptance:

  • Use the native wide path APIs and explicit UTF-8/UTF-16 conversion for input and returned paths.
  • Cover create/open/stat/rename/remove and current-directory round trips with Korean text and a supplementary-plane character.
  • Check output capacities in the units exposed by the Wave API and release all conversion buffers on error.
  • Do not require a process-wide UTF-8 code-page setting or introduce libc bindings.

API/reference context: Windows file naming and Unicode APIs.

Related: #385; the Windows environment block has a separate ownership and encoding path.

Audit status: identified by static source inspection; the scenarios above have not been executed during this audit. The permalink fixes the reviewed revision; this report does not claim the defect was introduced by #520.

Activity

  1. added
    bug
    help wanted
    cross-platform
    on Sep 8, 2026
  2. self-assigned this
    on Sep 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugcross-platformhelp wanted

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions