]> granicus.if.org Git - ipset/commit
Fix parallel resizing and listing of the same set
authorJozsef Kadlecsik <kadlec@blackhole.kfki.hu>
Sat, 25 Oct 2014 22:11:29 +0000 (00:11 +0200)
committerJozsef Kadlecsik <kadlec@blackhole.kfki.hu>
Tue, 18 Nov 2014 07:08:59 +0000 (08:08 +0100)
commitab37682708b57c664acdf7b9122773bc71d25bde
treed8d51bb34824662eb08015173d18794434fdc134
parent1ad6ec25d566c8e1c8fe2f16d265f8f0cafdc76a
Fix parallel resizing and listing of the same set

When elements added to a hash:* type of set and resizing triggered,
parallel listing could start to list the original set (before resizing)
and "continue" with listing the new set. Fix it by references and
using the original hash table for listing. Therefore the destroying
the original hash table may happen from the resizing or listing functions.
kernel/include/linux/netfilter/ipset/ip_set.h
kernel/net/netfilter/ipset/ip_set_core.c
kernel/net/netfilter/ipset/ip_set_hash_gen.h
tests/hash:ip.t
tests/resize-and-list.sh [new file with mode: 0755]