mirror of
https://github.com/znc/znc.git
synced 2026-07-03 16:31:49 +02:00
Try to fix memory leak.
This commit is contained in:
+4
-1
@@ -886,7 +886,10 @@ bool CUser::IsHostAllowed(const CString& sHostMask) const {
|
||||
|
||||
iIsRangeValid = getaddrinfo(vsSplitCIDR.front().c_str(), NULL,
|
||||
&aiHints, &aiRange);
|
||||
if (iIsRangeValid != 0) continue;
|
||||
if (iIsRangeValid != 0) {
|
||||
freeaddrinfo(aiHost);
|
||||
continue;
|
||||
}
|
||||
|
||||
// "/0" allows all IPv[4|6] addresses
|
||||
if (iRoutingPrefix == 0) return true;
|
||||
|
||||
Reference in New Issue
Block a user