From 85762a62d478155e87c32b0f6b5208622f08a449 Mon Sep 17 00:00:00 2001 From: alfred Date: Wed, 24 Jul 2002 00:29:22 +0000 Subject: [PATCH] Attempt to clarify comment in selrecord. --- sys/kern/sys_generic.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/sys/kern/sys_generic.c b/sys/kern/sys_generic.c index e4e40cfc867..165284c472c 100644 --- a/sys/kern/sys_generic.c +++ b/sys/kern/sys_generic.c @@ -1147,10 +1147,14 @@ selrecord(selector, sip) mtx_lock(&sellock); /* - * If the thread is NULL then take ownership of selinfo - * however if the thread is not NULL and the thread points to - * someone else, then we have a collision, otherwise leave it alone - * as we've owned it in a previous selrecord on this selinfo. + * If the selinfo's thread pointer is NULL then take ownership of it. + * + * If the thread pointer is not NULL and it points to another + * thread, then we have a collision. + * + * If the thread pointer is not NULL and points back to us then leave + * it alone as we've already added pointed it at us and added it to + * our list. */ if (sip->si_thread == NULL) { sip->si_thread = selector; -- 2.45.2