From owner-freebsd-hackers Wed Oct 31 7:48:28 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from math.missouri.edu (math.missouri.edu [128.206.49.180]) by hub.freebsd.org (Postfix) with ESMTP id A901337B403 for ; Wed, 31 Oct 2001 07:48:23 -0800 (PST) Received: from math.missouri.edu (cauchy.math.missouri.edu [128.206.49.166]) by math.missouri.edu (8.11.3/8.11.3) with ESMTP id f9VFmLX35170; Wed, 31 Oct 2001 09:48:21 -0600 (CST) (envelope-from stephen@math.missouri.edu) Message-ID: <3BE01D41.AB45760C@math.missouri.edu> Date: Wed, 31 Oct 2001 09:48:17 -0600 From: Stephen Montgomery-Smith Organization: University of Missouri X-Mailer: Mozilla 4.78 [en] (X11; U; Linux 2.2.12 i386) X-Accept-Language: en MIME-Version: 1.0 To: Arjan Knepper Cc: hackers FreeBSD Subject: Re: Simple pthread question References: <3BDFB5B5.5090102@jak.nl> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG I have successfully used sleep in this situation. I wanted a process that activated every hour (it did some "garbage collection"), so it went something like while (1) { sleep(3600); do_stuff(); } and the other threads worked fine. Arjan Knepper wrote: > > How do I suspend one particular thread without suspending the whole process? > I can not use sleep or usleep can I? > > TIA > Arjan > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-hackers" in the body of the message -- Stephen Montgomery-Smith stephen@math.missouri.edu http://www.math.missouri.edu/~stephen To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message