merge: 合并代码20240706

This commit is contained in:
TsMask committed 2024-07-06 18:27:00 +08:00
1 parent 3b50e2f3f8
commit 49860c2f28
145 files changed
+4366 -4051

No files matched your search

+2 -2
View File
@@ -172,10 +172,10 @@ func Color(colorStr string) *color.RGBA {
}
}
// ConvertIPMask 转换IP网络地址掩码 24 -> 255.255.255.0
// ConvertIPMask 转换IP网络地址掩码 24->"255.255.255.0" 20->"255.255.240.0"
func ConvertIPMask(bits int64) string {
if bits < 0 || bits > 32 {
return "Invalid Mask Bits"
return "255.255.255.255"
}
// 构建一个32位的uint32类型掩码,指定前bits位为1,其余为0