mirror of
https://github.com/obsproject/obs-studio.git
synced 2026-09-19 09:41:32 +08:00
UI: Fix possible use-after-free of obs_source_t
Also removes an implicit pair of successive obs_source_getref and obs_source_release calls from OBSSource.
This commit is contained in:
@@ -114,8 +114,8 @@ struct OBSStudioAPI : obs_frontend_callbacks {
|
||||
struct obs_frontend_source_list *sources) override
|
||||
{
|
||||
for (int i = 0; i < main->ui->transitions->count(); i++) {
|
||||
obs_source_t *tr = main->ui->transitions->itemData(i)
|
||||
.value<OBSSource>();
|
||||
OBSSource tr = main->ui->transitions->itemData(i)
|
||||
.value<OBSSource>();
|
||||
|
||||
if (!tr)
|
||||
continue;
|
||||
|
||||
Reference in New Issue
Block a user