https://bugs.winehq.org/show_bug.cgi?id=48229 --- Comment #5 from Paul Gofman <gofmanp(a)gmail.com> --- Created attachment 66257 --> https://bugs.winehq.org/attachment.cgi?id=66257 Proof of concept fix I am attaching the patch which fixes the issue. This patch certainly needs some refinement, as, at least: - the straight coded '__attribute__((noinline))' is important, as without it gcc starts inlining CreateFileW() into CreateFileA() and we are back where we started. But it needs to be defined somewhere, maybe even inside the definition of WINAPI or DECLSPEC_HOTPATCH to avoid the similar issues with different functions; - All the other code from kernel32 should probably call the same kernel32 exported functions. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.