提交 f26cb706 编写于 作者: J jp9000

Clean up the previous commit a bit

The was_removed variable was rather unnecessary
上级 f2e1ce53
......@@ -331,7 +331,6 @@ int obs_sceneitem_release(obs_sceneitem_t item)
void obs_sceneitem_remove(obs_sceneitem_t item)
{
obs_scene_t scene;
bool was_removed;
if (!item)
return;
......@@ -341,15 +340,14 @@ void obs_sceneitem_remove(obs_sceneitem_t item)
if (scene)
pthread_mutex_lock(&scene->mutex);
was_removed = item->removed;
item->removed = true;
if (was_removed) {
if (item->removed) {
if (scene)
pthread_mutex_unlock(&scene->mutex);
return;
}
item->removed = true;
signal_item_remove(item);
detach_sceneitem(item);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册