https://bugs.winehq.org/show_bug.cgi?id=45972
--- Comment #2 from Dmitry Timoshkov dmitry@baikal.ru --- (In reply to Hans Leidekker from comment #1)
Created attachment 62538 [details] patch
Something like this should fix it.
The patch does fix the issue. Thanks Hans.