]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Improve unix socket PCB refcounting.
authorMark Johnston <markj@FreeBSD.org>
Tue, 15 Sep 2020 19:21:58 +0000 (19:21 +0000)
committerMark Johnston <markj@FreeBSD.org>
Tue, 15 Sep 2020 19:21:58 +0000 (19:21 +0000)
commit5362170da71cbe487b6d6a048b2e59de8901d504
tree279b61d83989f16851774d6bbdfde02821481fda
parentd5cbccecd857bfc520cd3859391167e6f7beea05
Improve unix socket PCB refcounting.

- Use refcount_init().
- Define an INVARIANTS-only zone destructor to assert that various
  bits of PCB state aren't left dangling.
- Annotate unp_pcb_rele() with __result_use_check.
- Simplify control flow.

Reviewed by: glebius, kevans, kib
Tested by: pho
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D26295
sys/kern/uipc_usrreq.c