PeekMsg/MsgWaitForMultipleObjects question

Alexandre Julliard julliard at
Tue Feb 23 03:20:02 CST 2010

<Joerg-Cyril.Hoehle at> writes:

> hopefully somebody familiar with messaging can immediately spot what's wrong
> with the code below.
> The winmm/midi tests currently in git, using PeekMsg, show that the messages
> (from CALLBACK_WINDOW) are almost always immediately available.
> Yet the code below, based on MsgWaitFor... times out multiple times
> during each test run. Why?

Message waiting functions only return for new input. You need to make
sure the queue is empty before waiting.

Alexandre Julliard
julliard at

More information about the wine-devel mailing list