[12/20] net/ice: goto clean up lable to avoid memory leak
Checks
Commit Message
When function return in this branch, the memories of 'input' and 'rule'
are not released, goto corresponding lable to do the clean up.
Fixes: 40d466fa9f765b ("net/ice: support ACL filter in DCF")
Signed-off-by: Weiguo Li <liwg06@foxmail.com>
---
drivers/net/ice/ice_acl_filter.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
@@ -530,7 +530,7 @@ ice_acl_create_filter(struct ice_adapter *ad,
RTE_FLOW_ERROR_TYPE_HANDLE, NULL,
"failed to set hw configure.");
ret = -rte_errno;
- return ret;
+ goto err_acl_set_input;
}
if (flow_type == ICE_FLTR_PTYPE_NONF_IPV4_OTHER) {