mirror of
https://gitlab.com/kicad/code/kicad.git
synced 2025-09-14 10:13:19 +02:00
Iterator safety.
This commit is contained in:
parent
808bcdda0f
commit
541ca43d9e
@ -145,6 +145,7 @@ static void add_category( const std::string& aCategoryPath, CATEGORY_STORE& aCat
|
|||||||
|
|
||||||
aCategoryStore.try_emplace( aCategoryStore.end(), aCategoryPath, categoryNode.get() );
|
aCategoryStore.try_emplace( aCategoryStore.end(), aCategoryPath, categoryNode.get() );
|
||||||
|
|
||||||
|
if( parent_iter != aCategoryStore.end() )
|
||||||
parent_iter->second->push_back( std::move( categoryNode ) );
|
parent_iter->second->push_back( std::move( categoryNode ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user