mirror of
https://github.com/opennetworkinglab/onos.git
synced 2025-10-17 02:11:38 +02:00
ONOS-4975 Fixed potential for IOB exception in intent perf installer.
Change-Id: Ia0af1dbbad586a4c64883e20b80cb1ffbe251cd4
This commit is contained in:
parent
682c19e562
commit
3a02cdabf2
@ -425,7 +425,7 @@ public class IntentPerfInstaller {
|
||||
private Iterable<Intent> subset(Set<Intent> intents) {
|
||||
List<Intent> subset = Lists.newArrayList(intents);
|
||||
Collections.shuffle(subset);
|
||||
return subset.subList(0, lastCount);
|
||||
return subset.subList(0, Math.min(intents.size(), lastCount));
|
||||
}
|
||||
|
||||
// Submits the specified intent.
|
||||
|
Loading…
x
Reference in New Issue
Block a user