aboutsummaryrefslogtreecommitdiffstats
path: root/Alc/mixer.c
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2011-10-04 22:39:35 -0700
committerChris Robinson <[email protected]>2011-10-04 22:39:35 -0700
commit75fee8c11f76889285e3b68cc1f3d13e92dacc26 (patch)
tree89e4ceabb2bd14d18304408db70b78de38264d7f /Alc/mixer.c
parent9e11b0a8c6c521a0c8b4dc4ed7c05017a787ca62 (diff)
Add min/max/clamp methods for 64-bit int
Diffstat (limited to 'Alc/mixer.c')
-rw-r--r--Alc/mixer.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/Alc/mixer.c b/Alc/mixer.c
index 231aa0fd..4646a262 100644
--- a/Alc/mixer.c
+++ b/Alc/mixer.c
@@ -565,8 +565,7 @@ ALvoid MixSource(ALsource *Source, ALCdevice *Device, ALuint SamplesToDo)
DataSize64 += BufferPadding+BufferPrePadding;
DataSize64 *= NumChannels;
- BufferSize = (ALuint)((DataSize64 > STACK_DATA_SIZE/sizeof(ALfloat)) ?
- STACK_DATA_SIZE/sizeof(ALfloat) : DataSize64);
+ BufferSize = (ALuint)mini64(DataSize64, STACK_DATA_SIZE/sizeof(ALfloat));
BufferSize /= NumChannels;
if(Source->lSourceType == AL_STATIC)