projects
/
openvswitch
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b18fcf8
)
netlink: Log duplicate attributes in nl_policy_parse().
author
Ben Pfaff
<blp@nicira.com>
Tue, 11 Jan 2011 22:12:03 +0000
(14:12 -0800)
committer
Ben Pfaff
<blp@nicira.com>
Thu, 27 Jan 2011 17:26:05 +0000
(09:26 -0800)
This made finding one particular bug slightly easier for me.
Reviewed by Justin Pettit.
lib/netlink.c
patch
|
blob
|
history
diff --git
a/lib/netlink.c
b/lib/netlink.c
index 48a52ee343172766e89eb6bfa9619502b7932967..725bba02f203324e679be9c3fe01f638f7f72318 100644
(file)
--- a/
lib/netlink.c
+++ b/
lib/netlink.c
@@
-582,6
+582,9
@@
nl_policy_parse(const struct ofpbuf *msg, size_t nla_offset,
assert(n_required > 0);
--n_required;
}
+ if (attrs[type]) {
+ VLOG_DBG_RL(&rl, "%zu: duplicate attr %"PRIu16, offset, type);
+ }
attrs[type] = nla;
} else {
/* Skip attribute type that we don't care about. */