Use unsafe merge in joinResults.addChildAndChildren(), for performance

This commit is contained in:
Bryan Boreham
2018-04-15 09:39:21 +00:00
parent b8dae7768d
commit 3711876194
2 changed files with 8 additions and 1 deletions
+1 -1
View File
@@ -203,7 +203,7 @@ func (ret *joinResults) addChild(m report.Node, id string, topology string) {
func (ret *joinResults) addChildAndChildren(m report.Node, id string, topology string) {
ret.addUnmappedChild(m, id, topology)
result := ret.nodes[id]
result.Children = result.Children.Merge(m.Children)
result.Children.UnsafeMerge(m.Children)
ret.nodes[id] = result
ret.mapChild(m.ID, id)
}