aboutsummaryrefslogtreecommitdiffstats
path: root/Alc/ALc.c
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2010-03-17 19:46:20 -0700
committerChris Robinson <[email protected]>2010-03-17 19:46:20 -0700
commit186e0f3b040308152175d3f6dca0efca8e3a8b2c (patch)
tree5b6e9fb02ad5c9939ad64c668b7fa8401ecbc0b1 /Alc/ALc.c
parent2e6c5e590f43e396270b03317d020eb3abc5d8c9 (diff)
Use a separate list for NULL-device extensions
Diffstat (limited to 'Alc/ALc.c')
-rw-r--r--Alc/ALc.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/Alc/ALc.c b/Alc/ALc.c
index 11d125a8..5eb87567 100644
--- a/Alc/ALc.c
+++ b/Alc/ALc.c
@@ -180,6 +180,9 @@ static ALCchar *alcDefaultAllDeviceSpecifier;
static ALCchar *alcCaptureDefaultDeviceSpecifier;
+static const ALCchar alcNoDeviceExtList[] =
+ "ALC_ENUMERATE_ALL_EXT ALC_ENUMERATION_EXT ALC_EXT_CAPTURE "
+ "ALC_EXTX_thread_local_context";
static const ALCchar alcExtensionList[] =
"ALC_ENUMERATE_ALL_EXT ALC_ENUMERATION_EXT ALC_EXT_CAPTURE "
"ALC_EXT_disconnect ALC_EXT_EFX ALC_EXTX_thread_local_context";
@@ -945,7 +948,10 @@ ALCAPI const ALCchar* ALCAPIENTRY alcGetString(ALCdevice *pDevice,ALCenum param)
break;
case ALC_EXTENSIONS:
- value = alcExtensionList;
+ if(IsDevice(pDevice))
+ value = alcExtensionList;
+ else
+ value = alcNoDeviceExtList;
break;
default:
@@ -1124,7 +1130,7 @@ ALCAPI ALCboolean ALCAPIENTRY alcIsExtensionPresent(ALCdevice *device, const ALC
size_t len;
len = strlen(extName);
- ptr = alcExtensionList;
+ ptr = (IsDevice(device) ? alcExtensionList : alcNoDeviceExtList);
while(ptr && *ptr)
{
if(strncasecmp(ptr, extName, len) == 0 &&