Changeset 70839 in vbox
- Timestamp:
- Jan 31, 2018 4:00:25 PM (7 years ago)
- svn:sync-xref-src-repo-rev:
- 120651
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Audio/DrvHostDSound.cpp
r70705 r70839 437 437 for (unsigned i = 0; i < DRV_DSOUND_RESTORE_ATTEMPTS_MAX; i++) 438 438 { 439 *ppv1 = *ppv2 = NULL;440 *pcb1 = *pcb2 = 0;441 hr = IDirectSoundBuffer8_Lock(pStreamDS->Out.pDSB, dwOffset, dwBytes, ppv1, pcb1, ppv2, pcb2, dwFlags);439 PVOID pv1, pv2; 440 DWORD cb1, cb2; 441 hr = IDirectSoundBuffer8_Lock(pStreamDS->Out.pDSB, dwOffset, dwBytes, &pv1, &cb1, &pv2, &cb2, dwFlags); 442 442 if (SUCCEEDED(hr)) 443 443 { 444 if ( (!*ppv1 || !(*pcb1 & pStreamDS->uAlign)) 445 && (!*ppv2 || !(*pcb2 & pStreamDS->uAlign)) ) 444 if ( (!pv1 || !(cb1 & pStreamDS->uAlign)) 445 && (!pv2 || !(cb2 & pStreamDS->uAlign))) 446 { 447 if (ppv1) 448 *ppv1 = pv1; 449 if (ppv2) 450 *ppv2 = pv2; 451 if (pcb1) 452 *pcb1 = cb1; 453 if (pcb2) 454 *pcb2 = cb2; 446 455 return S_OK; 456 } 447 457 DSLOGREL(("DSound: Locking playback buffer returned misaligned buffer: cb1=%#RX32, cb2=%#RX32 (alignment: %#RX32)\n", 448 458 *pcb1, *pcb2, pStreamDS->uAlign)); 449 directSoundPlayUnlock(pThis, pStreamDS->Out.pDSB, *ppv1, *ppv2, *pcb1, *pcb2);459 directSoundPlayUnlock(pThis, pStreamDS->Out.pDSB, pv1, pv2, cb1, cb2); 450 460 return E_FAIL; 451 461 }
Note:
See TracChangeset
for help on using the changeset viewer.