Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 122389
b: refs/heads/master
c: ea5693c
h: refs/heads/master
i:
  122387: 37b0606
v: v3
  • Loading branch information
Patrick McHardy authored and David S. Miller committed Nov 28, 2008
1 parent d1e8b58 commit 068e222
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: ed77a89c30fa03dcb234a84ddea710b3fb7b62da
refs/heads/master: ea5693ccc553951ae44cb963b28cce85edc275c9
6 changes: 6 additions & 0 deletions trunk/net/netlink/attr.c
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,12 @@ static int validate_nla(struct nlattr *nla, int maxtype,
if (attrlen < NLA_ALIGN(pt->len) + NLA_HDRLEN + nla_len(nla))
return -ERANGE;
break;
case NLA_NESTED:
/* a nested attributes is allowed to be empty; if its not,
* it must have a size of at least NLA_HDRLEN.
*/
if (attrlen == 0)
break;
default:
if (pt->len)
minlen = pt->len;
Expand Down

0 comments on commit 068e222

Please sign in to comment.