router: workaround for assertion fail on NODE::Add(unique_ptr<LINE>)
This commit is contained in:
parent
dd1a780d1f
commit
213d30cad6
|
@ -719,6 +719,14 @@ void NODE::Add( std::unique_ptr< ITEM > aItem, bool aAllowRedundant )
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ITEM::LINE_T:
|
case ITEM::LINE_T:
|
||||||
|
{
|
||||||
|
//fixme(twl): I don't like unique_ptr in this methods as the router has its own garbage collecting
|
||||||
|
//mechanism. This particular case is used exclusively in ROUTER::GetUpdatedItems() for
|
||||||
|
//dumping debug logs. Please don't call Add ( up<LINE> ) otherwise, dragons live here.
|
||||||
|
LINE *l = static_cast<LINE*>( aItem.get() );
|
||||||
|
Add( *l );
|
||||||
|
break;
|
||||||
|
}
|
||||||
default:
|
default:
|
||||||
assert( false );
|
assert( false );
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue