Commit 9162c3d3 authored by Ken Thomases's avatar Ken Thomases Committed by Alexandre Julliard

winecoreaudio: Fix a leak.

parent 35555862
...@@ -344,8 +344,10 @@ HRESULT WINAPI AUDDRV_GetEndpointIDs(EDataFlow flow, WCHAR ***ids, ...@@ -344,8 +344,10 @@ HRESULT WINAPI AUDDRV_GetEndpointIDs(EDataFlow flow, WCHAR ***ids,
buffers = HeapAlloc(GetProcessHeap(), 0, size); buffers = HeapAlloc(GetProcessHeap(), 0, size);
if(!buffers){ if(!buffers){
HeapFree(GetProcessHeap(), 0, devices); HeapFree(GetProcessHeap(), 0, devices);
for(j = 0; j < *num; ++j) for(j = 0; j < *num; ++j){
HeapFree(GetProcessHeap(), 0, (*ids)[j]); HeapFree(GetProcessHeap(), 0, (*ids)[j]);
HeapFree(GetProcessHeap(), 0, (*keys)[j]);
}
HeapFree(GetProcessHeap(), 0, *keys); HeapFree(GetProcessHeap(), 0, *keys);
HeapFree(GetProcessHeap(), 0, *ids); HeapFree(GetProcessHeap(), 0, *ids);
return E_OUTOFMEMORY; return E_OUTOFMEMORY;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment