mirror of
https://github.com/vishvananda/netlink
synced 2025-04-17 20:55:39 +00:00
Return correct underlying error.
This commit is contained in:
parent
9462941794
commit
988716e658
@ -121,8 +121,9 @@ func parseAddr(m []byte) (addr Addr, family, index int, err error) {
|
||||
family = -1
|
||||
index = -1
|
||||
|
||||
attrs, err := nl.ParseRouteAttr(m[msg.Len():])
|
||||
if err != nil {
|
||||
attrs, err1 := nl.ParseRouteAttr(m[msg.Len():])
|
||||
if err1 != nil {
|
||||
err = err1
|
||||
return
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user