winealsa.drv: Ignore unused bytes in wave headers.

This commit is contained in:
Maarten Lankhorst 2010-04-08 21:54:50 +02:00 committed by Alexandre Julliard
parent adfe42ca3f
commit 8f6d268ee4
1 changed files with 1 additions and 1 deletions

View File

@ -256,7 +256,7 @@ static int wodPlayer_WriteMaxFrags(WINE_WAVEDEV* wwo, DWORD* frames)
written = 0;
wwo->dwPartialOffset += snd_pcm_frames_to_bytes(wwo->pcm, written);
if ( wwo->dwPartialOffset >= lpWaveHdr->dwBufferLength) {
if (wwo->dwPartialOffset + wwo->format.Format.nBlockAlign - 1 >= lpWaveHdr->dwBufferLength) {
/* this will be used to check if the given wave header has been fully played or not... */
wwo->dwPartialOffset = lpWaveHdr->dwBufferLength;
/* If we wrote all current wavehdr, skip to the next one */