Commit 872370e3 authored by Janoš Guljaš's avatar Janoš Guljaš Committed by Viktor Trón

swarm/network/simulation: do not copy node mutex in UploadSnapshot (#19160)

parent 81babe15
...@@ -222,11 +222,11 @@ func (s *Simulation) UploadSnapshot(snapshotFile string, opts ...AddNodeOption) ...@@ -222,11 +222,11 @@ func (s *Simulation) UploadSnapshot(snapshotFile string, opts ...AddNodeOption)
//the snapshot probably has the property EnableMsgEvents not set //the snapshot probably has the property EnableMsgEvents not set
//just in case, set it to true! //just in case, set it to true!
//(we need this to wait for messages before uploading) //(we need this to wait for messages before uploading)
for _, n := range snap.Nodes { for i := range snap.Nodes {
n.Node.Config.EnableMsgEvents = true snap.Nodes[i].Node.Config.EnableMsgEvents = true
n.Node.Config.Services = s.serviceNames snap.Nodes[i].Node.Config.Services = s.serviceNames
for _, o := range opts { for _, o := range opts {
o(n.Node.Config) o(snap.Nodes[i].Node.Config)
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment