Merge pull request #2485 from y67h41/fix-/0-CIDR

Make /0 CIDR parsed as IP
This commit is contained in:
2dust authored and GitHub committed 2023-09-01 22:33:13 +08:00
commit 4a85c95b02
2 files changed
+3 -1

No files matched your search

@@ -178,7 +178,7 @@ object Utils {
//CIDR
if (addr.indexOf("/") > 0) {
val arr = addr.split("/")
if (arr.count() == 2 && Integer.parseInt(arr[1]) > 0) {
if (arr.count() == 2 && Integer.parseInt(arr[1]) > -1) {
addr = arr[0]
}
}