Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:983 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 62751 invoked from network); 19 Apr 2003 22:52:07 -0000 Received: from unknown (HELO ns1.xprowler.com) (64.246.18.33) by pb1.pair.com with SMTP; 19 Apr 2003 22:52:07 -0000 Received: from Marshall (ppp-66-73-176-242.dsl.sfldmi.ameritech.net [66.73.176.242]) (authenticated (0 bits)) by ns1.xprowler.com (8.11.6/8.11.6) with ESMTP id h3JNH9230492; Sat, 19 Apr 2003 19:17:09 -0400 Message-ID: <001a01c306c6$692b6a10$6501a8c0@Marshall> To: Cc: References: <001a01c30644$2c0f5150$6501a8c0@Marshall> Date: Sat, 19 Apr 2003 18:52:51 -0400 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1106 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 Subject: Re: [PHP-DEV] Sharing resources between modules From: marshall@magpcss.com ("Marshall A. Greenblatt") ----- Original Message ----- From: "Marshall A. Greenblatt" To: Sent: Saturday, April 19, 2003 3:20 AM Subject: [PHP-DEV] Sharing resources between modules > Hi guys, a quick question: > > Is it possible for one module to retrieve the resource structure registered > by another module? > [snip] > res_type = zend_fetch_list_dtor_id("my structure"); > mystructp = (mystruct*)zend_fetch_resource(&myzvalp TSRMLS_CC, > -1, "my structure", > NULL, 1, res_type); [snip] The zend_fetch_list_dtor_id() function works as I expected; it returns the resource type ID for the specified resource name, irregardless of what module that ID was originally registered in. As long as both modules know the name of the resource, I don't have to export the value returned from zend_register_list_destructors_ex(). Thanks for the response Wez! - Marshall