Skip to content
Snippets Groups Projects
Commit 93f4e600 authored by Sébastien Blin's avatar Sébastien Blin Committed by Andreas Traczyk
Browse files

avmodel: avoid some useless lookups

GitLab: #441
Change-Id: Ie1b696f2648530f385ed00075d32a9d81bcd0d63
parent 07f52257
No related branches found
No related tags found
No related merge requests found
......@@ -796,11 +796,11 @@ AVModelPimpl::stoppedDecoding(const QString& id, const QString& shmPath)
return; // nothing to do
}
if (searchFinished->second) {
disconnect(&*renderers_[id],
disconnect(&*search->second,
&api::video::Renderer::frameUpdated,
this,
&AVModelPimpl::slotFrameUpdated);
renderers_.erase(id);
renderers_.erase(search);
#ifndef ENABLE_LIBWRAP
SIZE_RENDERER = renderers_.size();
#endif
......@@ -824,12 +824,12 @@ AVModelPimpl::slotCallStateChanged(const QString& id, const QString& state, int
qWarning() << "Renderer " << id << "not found";
return; // nothing to do
}
if (!(*search).second->isRendering()) {
disconnect(&*renderers_[id],
if (!search->second->isRendering()) {
disconnect(&*search->second,
&api::video::Renderer::frameUpdated,
this,
&AVModelPimpl::slotFrameUpdated);
renderers_.erase(id);
renderers_.erase(search);
#ifndef ENABLE_LIBWRAP
SIZE_RENDERER = renderers_.size();
#endif
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment