diff options
author | Pedro Tammela <pctammela@mojatatu.com> | 2023-02-24 14:57:56 -0300 |
---|---|---|
committer | Stephen Hemminger <stephen@networkplumber.org> | 2023-02-24 10:09:18 -0800 |
commit | 70b9ebae63ce7e6f9911bdfbcf47a6d18f24159a (patch) | |
tree | 424ba9f51f64f4f96568029d95c84e1725ef81fe /tc | |
parent | 4e0e56e0ef05387f7f5d8ab41fe6ec6a1897b26d (diff) | |
download | iproute2-70b9ebae63ce7e6f9911bdfbcf47a6d18f24159a.tar.gz |
tc: m_action: fix parsing of TCA_EXT_WARN_MSG
It should sit within the TCA_ACT_TAB hierarchy, otherwise the access to
tb is out of bounds:
./tc action ls action csum
total acts 1
action order 0: csum (?empty) action pass
index 1 ref 1 bind 0
not_in_hw
Segmentation fault (core dumped)
Fixes: 60359956 ("tc: add new attr TCA_EXT_WARN_MSG")
Reviewed-by: Jamal Hadi Salim <jhs@mojatatu.com>
Signed-off-by: Pedro Tammela <pctammela@mojatatu.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Diffstat (limited to 'tc')
-rw-r--r-- | tc/m_action.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tc/m_action.c b/tc/m_action.c index 0400132c..6c91af2c 100644 --- a/tc/m_action.c +++ b/tc/m_action.c @@ -586,7 +586,7 @@ int print_action(struct nlmsghdr *n, void *arg) open_json_object(NULL); tc_dump_action(fp, tb[TCA_ACT_TAB], tot_acts ? *tot_acts:0, false); - print_ext_msg(tb); + print_ext_msg(&tb[TCA_ACT_TAB]); close_json_object(); return 0; |