dcb: Set values with RTM_SETDCB type

dcb currently sends all netlink messages with a type RTM_GETDCB, even the
set ones. Change to the appropriate type.

Fixes: 67033d1c1c ("Add skeleton of a new tool, dcb")
Signed-off-by: Petr Machata <me@pmachata.org>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
This commit is contained in:
Petr Machata 2021-01-03 11:57:22 +01:00 committed by Stephen Hemminger
parent 8b4b132261
commit 2e99c28161
1 changed files with 1 additions and 1 deletions

View File

@ -177,7 +177,7 @@ int dcb_set_attribute(struct dcb *dcb, const char *dev, int attr, const void *da
struct nlattr *nest;
int ret;
nlh = dcb_prepare(dcb, dev, RTM_GETDCB, DCB_CMD_IEEE_SET);
nlh = dcb_prepare(dcb, dev, RTM_SETDCB, DCB_CMD_IEEE_SET);
nest = mnl_attr_nest_start(nlh, DCB_ATTR_IEEE);
mnl_attr_put(nlh, attr, data_len, data);