Commit fbd91e2d authored by Arthur Gautier's avatar Arthur Gautier Committed by Sasha Goldshtein

bfp, xdp: make type explicit

explicit the type of the nlattr
Signed-off-by: default avatarArthur Gautier <baloo@gandi.net>
parent 1179ac87
......@@ -637,7 +637,7 @@ int bpf_attach_xdp(const char *dev_name, int progfd) {
// we specify the FD passed over by the user
nla_xdp->nla_type = 1/*IFLA_XDP_FD*/;
nla_xdp->nla_len = NLA_HDRLEN + sizeof(int);
nla_xdp->nla_len = NLA_HDRLEN + sizeof(progfd);
memcpy((char *)nla_xdp + NLA_HDRLEN, &progfd, sizeof(progfd));
nla->nla_len = NLA_HDRLEN + nla_xdp->nla_len;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment