mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-11-30 10:52:50 +00:00
MFC r343591:
Do not obtain an already held read lock. This causes a witness panic when ipfs is invoked. This is the second of two panics resolving PR 235110. PR: 235110 Reported by: David.Boyd49@twc.com
This commit is contained in:
parent
19b7e9b2eb
commit
2f0b37465d
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/stable/10/; revision=344113
@ -1909,21 +1909,17 @@ ipf_nat_getent(softc, data, getlock)
|
||||
}
|
||||
}
|
||||
if (error == 0) {
|
||||
if (getlock) {
|
||||
READ_ENTER(&softc->ipf_nat);
|
||||
getlock = 0;
|
||||
}
|
||||
error = ipf_outobjsz(softc, data, ipn, IPFOBJ_NATSAVE,
|
||||
ipns.ipn_dsize);
|
||||
}
|
||||
|
||||
finished:
|
||||
if (getlock) {
|
||||
READ_ENTER(&softc->ipf_nat);
|
||||
}
|
||||
if (ipn != NULL) {
|
||||
KFREES(ipn, ipns.ipn_dsize);
|
||||
}
|
||||
if (getlock) {
|
||||
RWLOCK_EXIT(&softc->ipf_nat);
|
||||
}
|
||||
return error;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user