mirror of
https://github.com/CTCaer/RetroArch.git
synced 2025-01-19 01:12:33 +00:00
Fix potential segfault in AL.
This commit is contained in:
parent
fe1d9a5a2a
commit
8c4410158d
@ -67,8 +67,11 @@ static void al_free(void *data)
|
||||
free(al->buffers);
|
||||
free(al->res_buf);
|
||||
alcMakeContextCurrent(NULL);
|
||||
alcDestroyContext(al->ctx);
|
||||
alcCloseDevice(al->handle);
|
||||
|
||||
if (al->ctx)
|
||||
alcDestroyContext(al->ctx);
|
||||
if (al->handle)
|
||||
alcCloseDevice(al->handle);
|
||||
free(al);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user