Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 211097
b: refs/heads/master
c: 15cdead
h: refs/heads/master
i:
  211095: a4dbd72
v: v3
  • Loading branch information
Eric Dumazet authored and David S. Miller committed Sep 22, 2010
1 parent d5f404e commit 4efff56
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: b46ffb854554ff939701bdd492b81558da5706fc
refs/heads/master: 15cdeadaa5d76009e20c7792aed69f5a73808f97
4 changes: 3 additions & 1 deletion trunk/net/netfilter/nf_conntrack_extend.c
Original file line number Diff line number Diff line change
Expand Up @@ -48,15 +48,17 @@ nf_ct_ext_create(struct nf_ct_ext **ext, enum nf_ct_ext_id id, gfp_t gfp)
{
unsigned int off, len;
struct nf_ct_ext_type *t;
size_t alloc_size;

rcu_read_lock();
t = rcu_dereference(nf_ct_ext_types[id]);
BUG_ON(t == NULL);
off = ALIGN(sizeof(struct nf_ct_ext), t->align);
len = off + t->len;
alloc_size = t->alloc_size;
rcu_read_unlock();

*ext = kzalloc(t->alloc_size, gfp);
*ext = kzalloc(alloc_size, gfp);
if (!*ext)
return NULL;

Expand Down

0 comments on commit 4efff56

Please sign in to comment.