aboutsummaryrefslogtreecommitdiffstats
path: root/Alc/ALu.c
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2009-11-01 09:29:20 -0800
committerChris Robinson <[email protected]>2009-11-01 09:29:20 -0800
commitfb258a7416a879bc19b92a2bae262d7d709cea72 (patch)
tree5b2e466dbafa11e1323ef135012aee7ddf6c433a /Alc/ALu.c
parent5aed92788715cc957d6adb2b621f49f8ed22e162 (diff)
Properly lock the device when setting it disconnected
Diffstat (limited to 'Alc/ALu.c')
-rw-r--r--Alc/ALu.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/Alc/ALu.c b/Alc/ALu.c
index 2eb8d182..546da2c7 100644
--- a/Alc/ALu.c
+++ b/Alc/ALu.c
@@ -1362,6 +1362,7 @@ ALvoid aluHandleDisconnect(ALCdevice *device)
{
ALuint i;
+ SuspendContext(NULL);
for(i = 0;i < device->NumContexts;i++)
{
ALsource *source;
@@ -1384,4 +1385,5 @@ ALvoid aluHandleDisconnect(ALCdevice *device)
}
device->Connected = ALC_FALSE;
+ ProcessContext(NULL);
}