mirror of
https://git.code.sf.net/p/quake/newtree
synced 2024-11-21 19:51:18 +00:00
Check for null buffers from directsound. (forgot to commit, hm..)
This commit is contained in:
parent
01baf4a868
commit
d81eb19c1f
1 changed files with 14 additions and 4 deletions
|
@ -94,8 +94,13 @@ S_TransferStereo16 (int endtime)
|
|||
lpaintedtime = paintedtime;
|
||||
|
||||
#ifdef _WIN32
|
||||
// fixme: should check for NULL pbuf value
|
||||
if (pDSBuf) pbuf=DSOUND_LockBuffer(true);
|
||||
if (pDSBuf) {
|
||||
pbuf=DSOUND_LockBuffer(true);
|
||||
if(!pbuf) {
|
||||
Con_Printf("DSOUND_LockBuffer fails!\n");
|
||||
return;
|
||||
}
|
||||
}
|
||||
else
|
||||
#endif
|
||||
{
|
||||
|
@ -151,8 +156,13 @@ S_TransferPaintBuffer (int endtime)
|
|||
snd_vol = volume->value * 256;
|
||||
|
||||
#ifdef _WIN32
|
||||
// fixme: should check for NULL pbuf value
|
||||
if (pDSBuf) pbuf=DSOUND_LockBuffer(true);
|
||||
if (pDSBuf) {
|
||||
pbuf=DSOUND_LockBuffer(true);
|
||||
if(!pbuf) {
|
||||
Con_Printf("DSOUND_LockBuffer fails!\n");
|
||||
return;
|
||||
}
|
||||
}
|
||||
else
|
||||
#endif
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue