git.droids-corp.org
/
dpdk.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3c9be81
)
app/testpmd: fix memory leak on error path
author
Yunjian Wang
<wangyunjian@huawei.com>
Mon, 25 May 2020 01:46:23 +0000
(09:46 +0800)
committer
Ferruh Yigit
<ferruh.yigit@intel.com>
Thu, 28 May 2020 15:57:07 +0000
(17:57 +0200)
This patch fixes the resource leak issue.
Fixes:
e63b50162aa3
("app/testpmd: clean metering and policing commands")
Cc: stable@dpdk.org
Signed-off-by: Yunjian Wang <wangyunjian@huawei.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
app/test-pmd/cmdline_mtr.c
patch
|
blob
|
history
diff --git
a/app/test-pmd/cmdline_mtr.c
b/app/test-pmd/cmdline_mtr.c
index
caa7e98
..
ee16244
100644
(file)
--- a/
app/test-pmd/cmdline_mtr.c
+++ b/
app/test-pmd/cmdline_mtr.c
@@
-1262,6
+1262,7
@@
static void cmd_set_port_meter_policer_action_parsed(void *parsed_result,
ret = rte_mtr_policer_actions_update(port_id, mtr_id,
action_mask, actions, &error);
if (ret != 0) {
+ free(actions);
print_err_msg(&error);
return;
}