Return-Path: Delivered-To: apmail-httpd-dev-archive@www.apache.org Received: (qmail 5336 invoked from network); 13 Jan 2005 18:36:38 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 13 Jan 2005 18:36:38 -0000 Received: (qmail 54985 invoked by uid 500); 13 Jan 2005 18:36:34 -0000 Delivered-To: apmail-httpd-dev-archive@httpd.apache.org Received: (qmail 54935 invoked by uid 500); 13 Jan 2005 18:36:34 -0000 Mailing-List: contact dev-help@httpd.apache.org; run by ezmlm Precedence: bulk Reply-To: dev@httpd.apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list dev@httpd.apache.org Received: (qmail 54919 invoked by uid 99); 13 Jan 2005 18:36:34 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=RCVD_BY_IP,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (hermes.apache.org: domain of trawick@gmail.com designates 64.233.170.197 as permitted sender) Received: from rproxy.gmail.com (HELO rproxy.gmail.com) (64.233.170.197) by apache.org (qpsmtpd/0.28) with ESMTP; Thu, 13 Jan 2005 10:36:33 -0800 Received: by rproxy.gmail.com with SMTP id y7so53889rne for ; Thu, 13 Jan 2005 10:36:30 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:references; b=rfatRYw6Zxgy0+QVQZwYOBaf7hPY688KYUtfnor4S04fpxrHIhjQhn5lUAWYvBYzwmmqef0IHypiNJdqJfrn4N2JOCCsHIkuJ3tkHi3EmLFf/cfnWnb0a+H9AHDplZx1FznpKMG8zaNRd4j8pvXCQSLMfTl+C5ahgDYOmFko+s8= Received: by 10.38.126.8 with SMTP id y8mr147879rnc; Thu, 13 Jan 2005 10:36:30 -0800 (PST) Received: by 10.39.2.76 with HTTP; Thu, 13 Jan 2005 10:36:30 -0800 (PST) Message-ID: Date: Thu, 13 Jan 2005 13:36:30 -0500 From: Jeff Trawick Reply-To: Jeff Trawick To: dev@httpd.apache.org Subject: Re: APR and mutexes ? In-Reply-To: <25B01514-658D-11D9-A385-000A958871B8@oav.net> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit References: <25B01514-658D-11D9-A385-000A958871B8@oav.net> X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N On Thu, 13 Jan 2005 19:01:28 +0100, Xavier Beaudouin wrote: > Hello there, > > I have inside a Apache2 module a call to a non thread safe function. I > need then to do : > > mutex_set(); > call_to_non_thread_safe(); > unset_mutex(); > > Now I can do that using POSIX calls, but I really like to use APR calls. > > Is there any good doc apr_thread_mutex.h > or even an example module I can use to make such > work ? $ cd /apache/source/tree $ grep apr_thread_mutex `find modules -name '*.c'` These modules will give examples of where in Apache module the initialization should occur, as well as sample calls during request processing.