From c693e649e67b14d508a08a4a8cde191daa4596b0 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Sun, 19 May 2013 03:19:19 -0700 Subject: Fix a potential leak when mmdevapi fails to open --- Alc/backends/mmdevapi.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'Alc/backends/mmdevapi.c') diff --git a/Alc/backends/mmdevapi.c b/Alc/backends/mmdevapi.c index 2555c7f3..2181f274 100644 --- a/Alc/backends/mmdevapi.c +++ b/Alc/backends/mmdevapi.c @@ -878,6 +878,9 @@ static ALCenum MMDevApiOpenPlayback(ALCdevice *device, const ALCchar *deviceName CloseHandle(data->MsgEvent); data->MsgEvent = NULL; + free(data->devid); + data->devid = NULL; + free(data); device->ExtraData = NULL; -- cgit v1.2.3