View | Details | Raw Unified | Return to bug 235110 | Differences between
and this patch

Collapse All | Expand All

(-)b/sys/contrib/ipfilter/netinet/ip_nat.c (-7 / +3 lines)
Lines 1904-1924 ipf_nat_getent(softc, data, getlock) Link Here
1904
		}
1904
		}
1905
	}
1905
	}
1906
	if (error == 0) {
1906
	if (error == 0) {
1907
		if (getlock) {
1908
			READ_ENTER(&softc->ipf_nat);
1909
			getlock = 0;
1910
		}
1911
		error = ipf_outobjsz(softc, data, ipn, IPFOBJ_NATSAVE,
1907
		error = ipf_outobjsz(softc, data, ipn, IPFOBJ_NATSAVE,
1912
				     ipns.ipn_dsize);
1908
				     ipns.ipn_dsize);
1913
	}
1909
	}
1914
1910
1915
finished:
1911
finished:
1916
	if (getlock) {
1917
		READ_ENTER(&softc->ipf_nat);
1918
	}
1919
	if (ipn != NULL) {
1912
	if (ipn != NULL) {
1920
		KFREES(ipn, ipns.ipn_dsize);
1913
		KFREES(ipn, ipns.ipn_dsize);
1921
	}
1914
	}
1915
	if (getlock) {
1916
		RWLOCK_EXIT(&softc->ipf_nat);
1917
	}
1922
	return error;
1918
	return error;
1923
}
1919
}
1924
1920

Return to bug 235110