Re: [PHP-DEV] Throwing E_DEPRECATED on startup

2009-04-22 Thread Kalle Sommer Nielsen
2009/4/22 Hannes Magnusson :
>
> There are couple of issues with throwing errors at startup:
> 1) They are thrown so damn early that the user will never see them
> 2) run-tests.php gets very confused and starts expecting HTTP headers
> in the EXPECT section
>
> If we could delay the checks until after php_module_startup()..

The patch is just like the one in HEAD (for E_WARNINGS about removed
configurations), meaning that we may need to change it after there
aswell.

>
> -Hannes
>
>



-- 
Kalle Sommer Nielsen
ka...@php.net

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP-DEV] Throwing E_DEPRECATED on startup

2009-04-21 Thread Hannes Magnusson
2009/4/22 Johannes Schlüter :
> On Fri, 2009-02-06 at 20:06 +0100, Kalle Sommer Nielsen wrote:
>> I'd like to propose a change for when PHP starts to throw an
>> E_DEPRECATED notice for each of the deprecated ini directives (such as
>> register_globals, safe_mode ect.) like in HEAD where they just throw a
>> warning (more about that below). I have attached a patch for this in
>> 5.3 (which is the only branch this patch really relates to).
>
> Yeah.
>
> Good thing to notice the user of bad configuration. I'm wondering a bit
> how we can educate people about magic_quotes_gpc ... people who blindly
> disable them probably break stuff which is "secure" by accident. This is
> not only relevant to this patch though. The best idea I have is a clear
> pointer to the docs from the message ...

There are couple of issues with throwing errors at startup:
1) They are thrown so damn early that the user will never see them
2) run-tests.php gets very confused and starts expecting HTTP headers
in the EXPECT section

If we could delay the checks until after php_module_startup()..

-Hannes

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP-DEV] Throwing E_DEPRECATED on startup

2009-04-21 Thread Johannes Schlüter
On Fri, 2009-02-06 at 20:06 +0100, Kalle Sommer Nielsen wrote:
> I'd like to propose a change for when PHP starts to throw an
> E_DEPRECATED notice for each of the deprecated ini directives (such as
> register_globals, safe_mode ect.) like in HEAD where they just throw a
> warning (more about that below). I have attached a patch for this in
> 5.3 (which is the only branch this patch really relates to).

Yeah.

Good thing to notice the user of bad configuration. I'm wondering a bit
how we can educate people about magic_quotes_gpc ... people who blindly
disable them probably break stuff which is "secure" by accident. This is
not only relevant to this patch though. The best idea I have is a clear
pointer to the docs from the message ...

johannes


-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php