http://bugs.winehq.org/show_bug.cgi?id=27184
--- Comment #4 from Andrew Eikum aeikum@codeweavers.com 2011-08-08 08:13:41 CDT --- (In reply to comment #3)
The patch looks good to me except this hunk:
@@ -1781,7 +1792,7 @@ static HRESULT WINAPI AudioCaptureClient_GetBuffer(IAudioCaptureClient *iface, *flags = 0; This->written_frames += *frames; This->inbuf_frames -= *frames; - This->getbuf_last = TRUE; + This->getbuf_last = 0;
if(devpos || qpcpos) AudioClock_GetPosition_nolock(This, devpos, qpcpos, FALSE);
Should that not be "getbuf_last = *frames"? With your patch applied, I believe the subsequent ReleaseBuffer() will always fail with E_OUT_OF_ORDER.