Delete old actions when setting new

Noone should be calling this twice, but there's no need to leak memory if they do
remotes/offline-stg/wilder
Albert Astals Cid 8 years ago
parent 1de0f5465b
commit 3a060a1680
  1. 1
      core/action.cpp

@ -72,6 +72,7 @@ QVector< Action * > Action::nextActions() const
void Action::setNextActions( const QVector< Action * > &actions )
{
Q_D( Action );
qDeleteAll( d->m_nextActions );
d->m_nextActions = actions;
}

Loading…
Cancel
Save