Return-Path: Delivered-To: apmail-httpd-modules-dev-archive@locus.apache.org Received: (qmail 32078 invoked from network); 10 Jan 2008 01:44:25 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 10 Jan 2008 01:44:25 -0000 Received: (qmail 22433 invoked by uid 500); 10 Jan 2008 01:44:14 -0000 Delivered-To: apmail-httpd-modules-dev-archive@httpd.apache.org Received: (qmail 22397 invoked by uid 500); 10 Jan 2008 01:44:14 -0000 Mailing-List: contact modules-dev-help@httpd.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: modules-dev@httpd.apache.org Delivered-To: mailing list modules-dev@httpd.apache.org Received: (qmail 22388 invoked by uid 99); 10 Jan 2008 01:44:13 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 09 Jan 2008 17:44:13 -0800 X-ASF-Spam-Status: No, hits=1.2 required=10.0 tests=SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: local policy) Received: from [64.202.165.196] (HELO smtpout04-02.prod.mesa1.secureserver.net) (64.202.165.196) by apache.org (qpsmtpd/0.29) with SMTP; Thu, 10 Jan 2008 01:44:01 +0000 Received: (qmail 9628 invoked from network); 10 Jan 2008 01:43:51 -0000 Received: from unknown (67.162.45.134) by smtpout04-04.prod.mesa1.secureserver.net (64.202.165.199) with ESMTP; 10 Jan 2008 01:43:51 -0000 Message-ID: <47857856.4060304@rowe-clan.net> Date: Wed, 09 Jan 2008 19:43:50 -0600 From: "William A. Rowe, Jr." User-Agent: Thunderbird 2.0.0.9 (X11/20071115) MIME-Version: 1.0 To: modules-dev@httpd.apache.org Subject: Re: Help: How to call function on Apache quit References: In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org Erik Lotspeich wrote: > Hi William, > > Thanks for your response. > >> Your *loadable* module doesn't survive to the end of the proc pool >> because it's codepages were already unloaded. Be careful. > > So is there a way for a dynamically-loadable module to do any teardown > when Apache quits? It seems that there must be some signal, API, or > mechanism. Your module is unloaded at least twice, and then a 3rd, 4th, 5th time upon restarts. The conf pool represents the lifetime of that session. You get that as the apr_pool_t * argument to your register_hooks callback. Bill