Skip to content

Commit

Permalink
Fix SeedList initialization (#1363)
Browse files Browse the repository at this point in the history
  • Loading branch information
erikzhang authored Dec 15, 2019
1 parent 91e9898 commit 537d09e
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/neo/Network/P2P/LocalNode.cs
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,10 @@ public LocalNode(NeoSystem system)
// Start dns resolution in parallel

for (int i = 0; i < ProtocolSettings.Default.SeedList.Length; i++)
Task.Run(() => SeedList[i] = GetIpEndPoint(ProtocolSettings.Default.SeedList[i]));
{
int index = i;
Task.Run(() => SeedList[index] = GetIpEndPoint(ProtocolSettings.Default.SeedList[index]));
}
}
}

Expand Down

0 comments on commit 537d09e

Please sign in to comment.