mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-11-01 00:48:50 +00:00
ad5d07f4a9
The current CIPSO and CALIPSO refcounting scheme for the DOI definitions is a bit flawed in that we: 1. Don't correctly match gets/puts in netlbl_cipsov4_list(). 2. Decrement the refcount on each attempt to remove the DOI from the DOI list, only removing it from the list once the refcount drops to zero. This patch fixes these problems by adding the missing "puts" to netlbl_cipsov4_list() and introduces a more conventional, i.e. not-buggy, refcounting mechanism to the DOI definitions. Upon the addition of a DOI to the DOI list, it is initialized with a refcount of one, removing a DOI from the list removes it from the list and drops the refcount by one; "gets" and "puts" behave as expected with respect to refcounts, increasing and decreasing the DOI's refcount by one. Fixes: |
||
---|---|---|
.. | ||
Kconfig | ||
Makefile | ||
netlabel_addrlist.c | ||
netlabel_addrlist.h | ||
netlabel_calipso.c | ||
netlabel_calipso.h | ||
netlabel_cipso_v4.c | ||
netlabel_cipso_v4.h | ||
netlabel_domainhash.c | ||
netlabel_domainhash.h | ||
netlabel_kapi.c | ||
netlabel_mgmt.c | ||
netlabel_mgmt.h | ||
netlabel_unlabeled.c | ||
netlabel_unlabeled.h | ||
netlabel_user.c | ||
netlabel_user.h |