mirror of
https://github.com/obsproject/obs-studio.git
synced 2024-07-19 17:49:14 +00:00
UI: Fix potential crash with unsupported video cards
If a video card is unsupported, it will attempt to initialize the stats window, querying values from a video subsystem that doesn't exist, and crash instead of alerting the user that their hardware is unsupported.
This commit is contained in:
parent
aafe08db5c
commit
36394ab08d
|
@ -2774,7 +2774,8 @@ int OBSBasic::ResetVideo()
|
|||
ResizeProgram(ovi.base_width, ovi.base_height);
|
||||
}
|
||||
|
||||
OBSBasicStats::InitializeValues();
|
||||
if (ret == OBS_VIDEO_SUCCESS)
|
||||
OBSBasicStats::InitializeValues();
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue