http://bugs.winehq.org/show_bug.cgi?id=33555
--- Comment #1 from Dmitry Timoshkov dmitry@baikal.ru 2013-05-09 23:53:11 CDT --- Created attachment 44416 --> http://bugs.winehq.org/attachment.cgi?id=44416 kernel32: Terminate threads before unloading DLLs on process exit
Does the attached patch help?