[cairo-bugs] [Bug 103536] Windows filenames should be in UTF-8 encoding

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Sun Nov 5 10:43:24 UTC 2017


https://bugs.freedesktop.org/show_bug.cgi?id=103536

--- Comment #7 from Adrian Johnson <ajohnson at redneon.com> ---
_cairo_fopen() belongs in cairo-misc.c. Just before _cairo_win32_tmpfile()
would be a good place.

It needs to pass through the status returned by cairo_utf8_to_utf16. So
something like:

cairo_status_t
_cairo_fopen (const char *utf8_filename, const char *mode, FILE **file_out);

And add a comment that the status is for the filename conversion. It can return
success and file_out = NULL.

I wouldn't bother using it for hard coded file names. Only the calls to fopen()
where the user supplies the filename.

> On Unix platforms, the filename is
> + * passed directly to the system

It is all platforms except windows.

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.cairographics.org/archives/cairo-bugs/attachments/20171105/7decff38/attachment.html>


More information about the cairo-bugs mailing list