aboutsummaryrefslogtreecommitdiffstats
path: root/Alc/ALc.c
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2009-10-31 13:25:26 -0700
committerChris Robinson <[email protected]>2009-10-31 13:25:26 -0700
commit9d4390771034d19feaf23a45341cc58fafaced73 (patch)
treee44ce1671ac1f9fb6b66f97395d8380d097d6bf5 /Alc/ALc.c
parenta3fcd67a82c486e5409de5f6045f3147fb72179f (diff)
Properly free the device name
Diffstat (limited to 'Alc/ALc.c')
-rw-r--r--Alc/ALc.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/Alc/ALc.c b/Alc/ALc.c
index 7398e151..46d6ac27 100644
--- a/Alc/ALc.c
+++ b/Alc/ALc.c
@@ -657,9 +657,11 @@ ALCAPI ALCboolean ALCAPIENTRY alcCaptureCloseDevice(ALCdevice *pDevice)
ProcessContext(NULL);
+ ALCdevice_CloseCapture(pDevice);
+
free(pDevice->szDeviceName);
+ pDevice->szDeviceName = NULL;
- ALCdevice_CloseCapture(pDevice);
free(pDevice);
bReturn = ALC_TRUE;