Re: [PHP4BETA] TSRM problems... UMBRs everywhere:-((
| From: | Thies C. Arntzen | Date: | Thu, 23 Dec 1999 15:08:53 +0000 |
| Subject: | Re: [PHP4BETA] TSRM problems... UMBRs everywhere:-(( | ||
| References: | 1 | Groups: | php.version4 |
| Request: | Send a blank email to php-version4+get-8440@lists.php.net to get a copy of this message | ||
On Thu, 23 Dec 1999 zeev@zend.com wrote:
> On Thu, 23 Dec 1999, Thies C. Arntzen wrote:
>
> > hi,
> >
> > just did some purifying of the aolserver-module - but my point should also
> > apply to the Win32 ISAPI stuff.
> >
> > a lot of _ctor function do *NOT* initialize all TS-Globals correct. just
> > compare struct _zend_compiler_globals (Zend/zend_globals.h) and see which
> > of those values get initialized in compiler_globals_ctor().
> >
> > i've enclosed a patch that clear's all TLS memory before calling the
> > ctor.
>
> I'm not following - TSRM isn't supposed to initialize the memory it
> initializes. If you need any initialization, it's done in the
> constructor, and if it isn't, it's a constructor bug.
>
> Are you referring to something else?
no -
than i found a bug (maybe even a few)...
compiler_globals_ctor only initializes:
compiler_globals->function_table
compiler_globals->class_table
purify says that eg: CG(extended_info) is uninted when calling
phpinfo() in ZTS mode.
these kind of UMBRs are extremely hard to find! - in non-ZTS mode all the
globals are usually zeroed when the executable loads.
i promise you that you will notice an improvement of stability when using
my patch on Win32 - even though i think we *SHOULD* not use (my patch) but
instead fix all the _ctor() functions.
tc
>
>
> --
> PHP 4.0 Beta Mailing List <http://www.php.net/version4/>
> To unsubscribe, e-mail: php4beta-unsubscribe@lists.php.net
> For additional commands, e-mail: php4beta-help@lists.php.net
> To contact the list administrators, e-mail: php4beta-admin@lists.php.net
>
>
Thies C. Arntzen "One Big-Mac, Small Fries and a Coke!"
Digital Collections Phone +49 40 235350 Fax +49 40 23535180
Hammerbrookstr. 93 20097 Hamburg / Germany