mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-10-08 21:30:57 +00:00
use a synchronized set to fix bug 2973; however, now I'm seeing a NPE at a different spot. Related?
This commit is contained in:
1 parent
39573c8928
commit
39baea5873
1 file changed
+2
-1
+2
-1
@@ -2,6 +2,7 @@ package com.sap.sailing.domain.markpassingcalculation.impl;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.Comparator;
|
||||
import java.util.HashMap;
|
||||
import java.util.HashSet;
|
||||
@@ -76,7 +77,7 @@ public class CandidateChooserImpl implements CandidateChooser {
|
||||
candidates = new HashMap<>();
|
||||
List<Candidate> startAndEnd = Arrays.asList(start, end);
|
||||
for (Competitor c : race.getRace().getCompetitors()) {
|
||||
candidates.put(c, new TreeSet<Candidate>());
|
||||
candidates.put(c, Collections.synchronizedSet(new TreeSet<Candidate>()));
|
||||
currentMarkPasses.put(c, new HashMap<Waypoint, MarkPassing>());
|
||||
TreeSet<Candidate> fixedPasses = new TreeSet<Candidate>(new Comparator<Candidate>() {
|
||||
@Override
|
||||
|
||||
Reference in new issue
Block a user