addr防止空地址校验

pull/107/MERGE
RuoYi 2019-06-30 19:47:32 +08:00
parent da5cca0b90
commit ff878564e4
2 changed files with 4 additions and 1 deletions

View File

@ -12,7 +12,6 @@
</head> </head>
<body class="gray-bg"> <body class="gray-bg">
<body class="gray-bg">
<div class="wrapper wrapper-content"> <div class="wrapper wrapper-content">
<div class="row"> <div class="row">

View File

@ -51,6 +51,10 @@ public class IpUtils
private static boolean internalIp(byte[] addr) private static boolean internalIp(byte[] addr)
{ {
if (StringUtils.isNull(addr) || addr.length < 2)
{
return true;
}
final byte b0 = addr[0]; final byte b0 = addr[0];
final byte b1 = addr[1]; final byte b1 = addr[1];
// 10.x.x.x/8 // 10.x.x.x/8