Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3b236880 authored by Changli Gao's avatar Changli Gao Committed by Patrick McHardy
Browse files

netfilter: ct_extend: fix the wrong alloc_size



In function update_alloc_size(), sizeof(struct nf_ct_ext) is added twice
wrongly.

Signed-off-by: default avatarChangli Gao <xiaosuo@gmail.com>
Signed-off-by: default avatarPatrick McHardy <kaber@trash.net>
parent b468645d
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -144,9 +144,8 @@ static void update_alloc_size(struct nf_ct_ext_type *type)
		if (!t1)
			continue;

		t1->alloc_size = sizeof(struct nf_ct_ext)
				 + ALIGN(sizeof(struct nf_ct_ext), t1->align)
				 + t1->len;
		t1->alloc_size = ALIGN(sizeof(struct nf_ct_ext), t1->align) +
				 t1->len;
		for (j = 0; j < NF_CT_EXT_NUM; j++) {
			t2 = nf_ct_ext_types[j];
			if (t2 == NULL || t2 == t1 ||