mirror of
https://github.com/vishvananda/netlink
synced 2025-01-14 19:11:36 +00:00
fix: check for ext ACK TLVs
checking for Extended ACK in nlmsghdr flags should be done with bitwise AND op instead of OR op Signed-off-by: adrianc <adrianc@nvidia.com>
This commit is contained in:
parent
aa4f20db57
commit
95ab6696a5
@ -574,7 +574,7 @@ done:
|
||||
err = syscall.Errno(-errno)
|
||||
|
||||
unreadData := m.Data[4:]
|
||||
if m.Header.Flags|unix.NLM_F_ACK_TLVS != 0 && len(unreadData) > syscall.SizeofNlMsghdr {
|
||||
if m.Header.Flags&unix.NLM_F_ACK_TLVS != 0 && len(unreadData) > syscall.SizeofNlMsghdr {
|
||||
// Skip the echoed request message.
|
||||
echoReqH := (*syscall.NlMsghdr)(unsafe.Pointer(&unreadData[0]))
|
||||
unreadData = unreadData[nlmAlignOf(int(echoReqH.Len)):]
|
||||
|
Loading…
Reference in New Issue
Block a user