[Bug 265145] bectl: fix potential resource leak in bectl_locate_jail(), print_snapshots() and bectl_cmd_list()
Date: Mon, 11 Jul 2022 07:53:03 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=265145 Bug ID: 265145 Summary: bectl: fix potential resource leak in bectl_locate_jail(), print_snapshots() and bectl_cmd_list() Product: Base System Version: Unspecified Hardware: Any OS: Any Status: New Severity: Affects Many People Priority: --- Component: bin Assignee: bugs@FreeBSD.org Reporter: niejianglei2021@163.com bectl_locate_jail(), print_snapshots() and bectl_cmd_list() allocate resource with be_prop_list_alloc(). When some error occrus, relevant resource should be released with be_prop_list_free(). Forgetting the release operation will cause resource leak. This patch fix the resource leak with adding the missing be_prop_list_free() on the error path. -- You are receiving this mail because: You are the assignee for the bug.