Skip to content
Snippets Groups Projects
Commit fbb1e185 authored by Davide Beatrici's avatar Davide Beatrici Committed by Alexandre Julliard
Browse files

winealsa: Use standard allocator in AudioClient's Initialize.

parent 7cc24be0
Branches
Tags
No related merge requests found
......@@ -421,7 +421,7 @@ static ULONG WINAPI AudioClient_Release(IAudioClient3 *iface)
list_remove(&This->entry);
sessions_unlock();
}
HeapFree(GetProcessHeap(), 0, This->vols);
free(This->vols);
if (This->stream)
stream_release(This->stream, This->timer_thread);
HeapFree(GetProcessHeap(), 0, This);
......@@ -610,7 +610,7 @@ static HRESULT WINAPI AudioClient_Initialize(IAudioClient3 *iface,
return params.result;
}
This->vols = HeapAlloc(GetProcessHeap(), 0, channel_count * sizeof(float));
This->vols = malloc(channel_count * sizeof(float));
if(!This->vols){
params.result = E_OUTOFMEMORY;
goto exit;
......@@ -627,7 +627,7 @@ static HRESULT WINAPI AudioClient_Initialize(IAudioClient3 *iface,
exit:
if(FAILED(params.result)){
stream_release(stream, NULL);
HeapFree(GetProcessHeap(), 0, This->vols);
free(This->vols);
This->vols = NULL;
}else{
This->stream = stream;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment