mirror of
https://github.com/obsproject/obs-studio.git
synced 2024-09-19 20:32:15 +02:00
obs-ffmpeg: Close VAAPI device on vaInitialize fail
On some systems (eg. mine), VAAPI fails on vaInitialize. Valgrind was able to spot that the device was not being closed, and it appears to have been correct. This fixes a memory leak.
This commit is contained in:
parent
6457d7b429
commit
6c389271b3
@ -99,6 +99,7 @@ VADisplay vaapi_open_device(int *fd, const char *device_path,
|
||||
if (va_status != VA_STATUS_SUCCESS) {
|
||||
blog(LOG_ERROR, "VAAPI: Failed to initialize display in %s",
|
||||
func_name);
|
||||
vaapi_close_device(fd, va_dpy);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user