mirror of
https://github.com/WarmUpTill/SceneSwitcher.git
synced 2026-04-24 14:58:19 -05:00
Fix crash in getSourceSettings()
This commit is contained in:
parent
3ae1050488
commit
34527b08a9
|
|
@ -254,9 +254,14 @@ std::string getSourceSettings(OBSWeakSource ws)
|
|||
if (!ws) {
|
||||
return "";
|
||||
}
|
||||
|
||||
std::string settings;
|
||||
auto s = obs_weak_source_get_source(ws);
|
||||
obs_data_t *data = obs_source_get_settings(s);
|
||||
std::string settings = obs_data_get_json(data);
|
||||
auto json = obs_data_get_json(data);
|
||||
if (json) {
|
||||
settings = json;
|
||||
}
|
||||
obs_data_release(data);
|
||||
obs_source_release(s);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user