Commit 6d62182f authored by Jan Engelhardt's avatar Jan Engelhardt Committed by Patrick McHardy

netfilter: xt_quota: fix incomplete initialization

Commit v2.6.29-rc5-872-gacc738fe ("xtables: avoid pointer to self")
forgot to copy the initial quota value supplied by iptables into the
private structure, thus counting from whatever was in the memory
kmalloc returned.
Signed-off-by: default avatarJan Engelhardt <jengelh@medozas.de>
Signed-off-by: default avatarPatrick McHardy <kaber@trash.net>
parent 24955619
...@@ -54,6 +54,7 @@ static bool quota_mt_check(const struct xt_mtchk_param *par) ...@@ -54,6 +54,7 @@ static bool quota_mt_check(const struct xt_mtchk_param *par)
if (q->master == NULL) if (q->master == NULL)
return -ENOMEM; return -ENOMEM;
q->master->quota = q->quota;
return true; return true;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment