Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoerg Mueller <nexyon@gmail.com>2009-08-26 14:02:17 +0400
committerJoerg Mueller <nexyon@gmail.com>2009-08-26 14:02:17 +0400
commitadcb21b1f4b079f892e259446bab32c1bc74304f (patch)
tree6c1efcfe6f1531715db505564d357faf9d80c062 /intern/audaspace
parent36b85d4508106752b0595fcb5150fd19f90b8739 (diff)
Close the old audio device before and not after opening the new.
Diffstat (limited to 'intern/audaspace')
-rw-r--r--intern/audaspace/intern/AUD_C-API.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/intern/audaspace/intern/AUD_C-API.cpp b/intern/audaspace/intern/AUD_C-API.cpp
index 9481e2139e8..995d4c5f99e 100644
--- a/intern/audaspace/intern/AUD_C-API.cpp
+++ b/intern/audaspace/intern/AUD_C-API.cpp
@@ -77,6 +77,9 @@ int AUD_init(AUD_DeviceType device, AUD_Specs specs, int buffersize)
#endif
AUD_IDevice* dev = NULL;
+ if(AUD_device)
+ AUD_exit();
+
try
{
switch(device)
@@ -107,9 +110,6 @@ int AUD_init(AUD_DeviceType device, AUD_Specs specs, int buffersize)
return false;
}
- if(AUD_device)
- AUD_exit();
-
AUD_device = dev;
if(AUD_device->checkCapability(AUD_CAPS_3D_DEVICE))
AUD_3ddevice = dynamic_cast<AUD_I3DDevice*>(AUD_device);