Skip to content

Commit

Permalink
Merge pull request #393 from marcusgc/master
Browse files Browse the repository at this point in the history
fix operator type
  • Loading branch information
deivisonmarteleto authored Jun 20, 2024
2 parents 49913bd + ce7453e commit 76b33d8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion networkapi/ambiente/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -1976,7 +1976,7 @@ def searchNextAvailableCIDR(self, subnets, network_mask=None):
for idx in range(len(subnets)-1):
step = int(subnets[idx+1].network_first_ip) - int(subnets[idx].network_last_ip) - 1
if step >= 2 ** (32-int(network_mask)):
subnet = NETADDR(str(NETADDR(subnets[idx].network).next().ip) + "/" + network_mask)
subnet = NETADDR(str(NETADDR(subnets[idx].network).next().ip) + "/" + str(network_mask))
if subnet.ip == subnet.network and \
not ipaddr.IPNetwork(subnet).overlaps(ipaddr.IPNetwork(subnets[idx+1].network)):
return str(subnet)
Expand Down

0 comments on commit 76b33d8

Please sign in to comment.