netfilter: nft_quota: reset quota after dump
authorPablo Neira Ayuso <pablo@netfilter.org>
Sun, 11 Dec 2016 19:09:23 +0000 (20:09 +0100)
committerPablo Neira Ayuso <pablo@netfilter.org>
Wed, 14 Dec 2016 22:38:51 +0000 (23:38 +0100)
commit8010d7feb2f0367ae573ad601b2905e29db50cd3
tree5a53a2cd004e8fa0acc36b5743c2ab19f105a344
parenta220871be66f99d8957c693cf22ec67ecbd9c23a
netfilter: nft_quota: reset quota after dump

Dumping of netlink attributes may fail due to insufficient room in the
skbuff, so let's reset consumed quota if we succeed to put netlink
attributes into the skbuff.

Fixes: 43da04a593d8 ("netfilter: nf_tables: atomic dump and reset for stateful objects")
Reported-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
net/netfilter/nft_quota.c