iscsid(8): free data allocated by getaddrinfo(3)
Reviewed By: mav Sponsored by: NetApp, Inc. Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D27329
This commit is contained in:
parent
70e64ba449
commit
7db3d97e0f
@ -253,6 +253,10 @@ connection_new(int iscsi_fd, const struct iscsi_daemon_request *request)
|
||||
"using ICL kernel proxy: ISCSIDCONNECT", to_addr);
|
||||
}
|
||||
|
||||
if (from_ai != NULL)
|
||||
freeaddrinfo(from_ai);
|
||||
freeaddrinfo(to_ai);
|
||||
|
||||
return (conn);
|
||||
}
|
||||
#endif /* ICL_KERNEL_PROXY */
|
||||
@ -330,6 +334,10 @@ connection_new(int iscsi_fd, const struct iscsi_daemon_request *request)
|
||||
log_err(1, "failed to connect to %s", to_addr);
|
||||
}
|
||||
|
||||
if (from_ai != NULL)
|
||||
freeaddrinfo(from_ai);
|
||||
freeaddrinfo(to_ai);
|
||||
|
||||
return (conn);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user