From 43cfc097de3fd84d701d7b6528cea80a28315cb7 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Thu, 17 Jan 2008 12:57:22 -0800 Subject: Don't dereference ALContext if there's no context yet Patch by Evgeny A. Marchenko --- Alc/ALu.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Alc/ALu.c b/Alc/ALu.c index 9b2fd33a..d7bd5aa0 100644 --- a/Alc/ALu.c +++ b/Alc/ALu.c @@ -957,7 +957,7 @@ ALvoid aluMixData(ALCcontext *ALContext,ALvoid *buffer,ALsizei size,ALenum forma } break; case AL_FORMAT_STEREO8: - if(ALContext->bs2b) + if(ALContext && ALContext->bs2b) { for(i = 0;i < SamplesToDo;i++) { @@ -1039,7 +1039,7 @@ ALvoid aluMixData(ALCcontext *ALContext,ALvoid *buffer,ALsizei size,ALenum forma } break; case AL_FORMAT_STEREO16: - if(ALContext->bs2b) + if(ALContext && ALContext->bs2b) { for(i = 0;i < SamplesToDo;i++) { -- cgit v1.2.3