Fixes Coverity CID 709290: Dereference after null check (FORWARD_NULL)
Comparing "this->m_clipref" to null implies that "this->m_clipref" might be null.
717 else if (m_clipref) {
...
Passing null variable "this->m_clipref" to function "AbstractClipItem::info() const", which dereferences it. [show details]
733 info = m_clipref->info();
info.startPos = GenTime(-1);
info.track = 0;
}
- else {
+ else if (m_clipref) {
info = m_clipref->info();
}
CollapsibleEffect *current = getEffectByIndex(ix);
if (m_effectMetaInfo.trackMode) {
isSelected = currentEffect->effectIndex() == 1;
}
- else {
+ else if (m_clipref) {
isSelected = currentEffect->effectIndex() == m_clipref->selectedEffectIndex();
}
if (isSelected) currentEffect->setActive(true);