Skip to content

Commit

Permalink
nice
Browse files Browse the repository at this point in the history
  • Loading branch information
David Cooke committed Aug 13, 2021
1 parent 0c1328c commit 982a9ea
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ allprojects {
apply plugin: 'jacoco'

group = 'uk.co.ractf'
version = '0.0.68'
version = '0.0.69'

repositories {
maven { url "https://repo1.maven.org/maven2/" }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,11 +61,13 @@ public Map<PortMapping, PortBinding> allocate(final List<PortMapping> portMappin
}
}

lastTcpPort++;
lastUdpPort++;
if (portAllocations.getTcp().contains(lastTcpPort)) {
lastTcpPort++;
lastTcpPort = generatePort(min, max, portAllocations.getTcp());
}
if (portAllocations.getUdp().contains(lastUdpPort)) {
lastUdpPort++;
lastUdpPort = portAllocations.getUdp().contains(lastTcpPort) ? generatePort(min, max, portAllocations.getUdp()) : lastTcpPort;
}
}
return portBindings;
Expand Down

0 comments on commit 982a9ea

Please sign in to comment.