diff options
Diffstat (limited to 'sys')
-rw-r--r-- | sys/netkey/key.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/netkey/key.c b/sys/netkey/key.c index abb58f7..e38226a 100644 --- a/sys/netkey/key.c +++ b/sys/netkey/key.c @@ -1958,7 +1958,6 @@ key_spdadd(so, m, mhp) newsp->lifetime = lft ? lft->sadb_lifetime_addtime : 0; newsp->validtime = lft ? lft->sadb_lifetime_usetime : 0; - newsp->refcnt = 1; /* do not reclaim until I say I do */ newsp->state = IPSEC_SPSTATE_ALIVE; LIST_INSERT_TAIL(&sptree[newsp->dir], newsp, secpolicy, chain); @@ -7591,9 +7590,10 @@ key_sp_unlink(sp) { /* remove from SP index */ - if (__LIST_CHAINED(sp)) + if (__LIST_CHAINED(sp)) { LIST_REMOVE(sp, chain); - key_freesp(sp); + key_freesp(sp); + } } /* XXX too much? */ |