Free graphics subsystem if graphics fails to load
The graphics subsystem was not being freed here, for example if a required effect failed to compile it would still successfully have the graphics subsystem sans required effect. The graphics subsystem should be completely shut down if required libobs effects fail to compile.
This commit is contained in:
parent
9eab73ea85
commit
69fc9fb7fc
@ -671,8 +671,10 @@ int obs_reset_video(struct obs_video_info *ovi)
|
||||
|
||||
if (!video->graphics) {
|
||||
int errorcode = obs_init_graphics(ovi);
|
||||
if (errorcode != OBS_VIDEO_SUCCESS)
|
||||
if (errorcode != OBS_VIDEO_SUCCESS) {
|
||||
obs_free_graphics();
|
||||
return errorcode;
|
||||
}
|
||||
}
|
||||
|
||||
blog(LOG_INFO, "video settings reset:\n"
|
||||
|
Loading…
x
Reference in New Issue
Block a user