antonioribeiro / support

Support Classes
BSD 3-Clause "New" or "Revised" License
59 stars 49 forks source link

fixed Undefined offset in IpAddress::cidrToRange #19

Closed decowboy closed 5 years ago

decowboy commented 5 years ago

The cidrToRange() function is called by Firewall for any entry, not just cidr ranges. Because the parent function has the function call in a try-catch block, this isn't an issue.

However, many users report warnings thrown by cidrToRange(), as is referenced here: https://github.com/antonioribeiro/firewall/issues/137

These warnings aren't circumvented by the try-catch block, but this additional check should prevent them altogether.

mgkprod commented 5 years ago

Up 👍

antonioribeiro commented 5 years ago

Nice, thank you!