From owner-freebsd-questions Tue Sep 18 11:28:51 2001 Delivered-To: freebsd-questions@freebsd.org Received: from square.cnd.mcgill.ca (square.CND.McGill.CA [132.206.114.119]) by hub.freebsd.org (Postfix) with ESMTP id 7B6C037B40F for ; Tue, 18 Sep 2001 11:28:45 -0700 (PDT) Received: (from mat@localhost) by square.cnd.mcgill.ca (8.9.3/8.9.3) id OAA28466 for freebsd-questions@freebsd.org; Tue, 18 Sep 2001 14:28:42 -0400 (EDT) (envelope-from mat) Date: Tue, 18 Sep 2001 14:28:42 -0400 From: Mathew Kanner To: freebsd-questions@freebsd.org Subject: pthread_cond_signal question Message-ID: <20010918142842.F12608@cnd.mcgill.ca> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i Organization: I speak for myself, operating in Montreal, CANADA Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hello All, I hope that you can help me decifer the pthread and pthread_cond_signal man pages. -The pthread man page for pthread_cond_signal says: int pthread_cond_signal(pthread_cond_t *cond) Unblock at least one of the threads blocked on the specified condition variable. -And the pthread_cond_signal man page says: DESCRIPTION The pthread_cond_signal() function unblocks one thread waiting for the condition variable cond. All is fine if there is at least on thread waiting on the condition variable. However, if there are no threads waiting, then the call does not unblock a thread -- this is the behavior that I want but it differs from the man page. Can I rely on this behavior or am I missing something subtle? Thanks, --Mat To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message