http://bugs.winehq.org/show_bug.cgi?id=31882
--- Comment #59 from Austin English austinenglish@gmail.com 2012-10-29 15:12:45 CDT --- (In reply to comment #49)
Created attachment 42273 [details] patch
Actually, the attached patch seems fairly good at avoiding the issue. I'm not quite familiar enough with all the code to judge how proper this is, but the basic idea is to avoid making X11 calls until message handler has had a chance to finish.
Alexandre committed something similar: http://source.winehq.org/git/wine.git/commitdiff/b7582525a047018b08768e6672c...
that's probably worth retesting with.