mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-12 03:44:01 +00:00
zebra: Fix leaked fd.
When we detect an error condition, close down the opened fd. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com.
This commit is contained in:
parent
d6716be3d9
commit
af734bc7cf
@ -172,6 +172,7 @@ ns_id_t zebra_ns_id_get(const char *netnspath)
|
||||
if (sock < 0) {
|
||||
zlog_err("netlink( %u) socket() error: %s", sock,
|
||||
safe_strerror(errno));
|
||||
close(fd);
|
||||
return NS_UNKNOWN;
|
||||
}
|
||||
memset(&snl, 0, sizeof(snl));
|
||||
|
Loading…
Reference in New Issue
Block a user