router: Do not use reference to a temporary object. Prevent double freeing (m_joints). Draw tuned track always on top.
This commit is contained in:
parent
6989af7904
commit
e342744a32
|
@ -181,7 +181,7 @@ public:
|
|||
return m_linkedItems;
|
||||
}
|
||||
|
||||
PNS_ITEMSET Links() const
|
||||
PNS_ITEMSET& Links()
|
||||
{
|
||||
return m_linkedItems;
|
||||
}
|
||||
|
|
|
@ -82,13 +82,14 @@ PNS_NODE::~PNS_NODE()
|
|||
allocNodes.erase( this );
|
||||
#endif
|
||||
|
||||
m_joints.clear();
|
||||
|
||||
for( PNS_INDEX::ITEM_SET::iterator i = m_index->begin(); i != m_index->end(); ++i )
|
||||
{
|
||||
if( (*i)->BelongsTo( this ) )
|
||||
delete *i;
|
||||
}
|
||||
|
||||
|
||||
releaseGarbage();
|
||||
unlinkParent();
|
||||
|
||||
|
|
|
@ -274,7 +274,7 @@ void ROUTER_PREVIEW_ITEM::Line( const SHAPE_LINE_CHAIN& aLine, int aWidth, int a
|
|||
m_width = aWidth;
|
||||
m_color = assignColor( aStyle );
|
||||
m_type = PR_SHAPE;
|
||||
m_depth = -BaseOverlayDepth;
|
||||
m_depth = -1024; // TODO gal->GetMinDepth()
|
||||
m_shape = aLine.Clone();
|
||||
|
||||
ViewSetVisible( true );
|
||||
|
|
Loading…
Reference in New Issue