Re: safe_mode changes
| From: | Andi Gutmans | Date: | Sun, 19 Feb 2006 21:01:48 +0000 |
| Subject: | Re: safe_mode changes | ||
| References: | 1 2 3 | Groups: | php.pecl.dev |
| Request: | Send a blank email to pecl-dev+get-3504@lists.php.net to get a copy of this message | ||
At 09:08 AM 2/19/2006, Sara Golemon wrote:
Yeah that makes sense. It does mean that for now I need to keep PG(safe_mode), php_checkuid() and ENFORCE_SAFE_MODE around. So what I'll do for now is that I'll emit an E_WARNING if the latter two are used so that people have an easier time fixing their extensions; and at least the PECL extensions will compile with HEAD for now. As we get closer to a PHP 6 beta we might want to revisit and see how we handle it (#ifdef or branch).Any insight on how to go about this? If I just commit it seems that certain modules which are rolled for PHP 5.1 from HEAD would not have safe_mode anymore. I only want to remove it for PHP 6, not for PHP 5.x. #ifdef would seriously suck, because one of the nice things about this change is that it *really* cleans up a lot of code.While I certainly appreciate the effort you've put in, I think the only proper way to handle this is to not touch PECL exts (except perhaps the ones that actually have branching due to their inclusion in release bundles). Extension maintainers undestand that they may have to do some work to make their exts compatable with PHP6 changes anyway, this is just one of those. I havn't looked, but I imagine very few do direct safe_mode checks themselves but rather leave it to the streams layer with a simple ENFORCE_SAFE_MODE flag. If we leave this define in place (resolving to 0 of course) then that particular compatability will be a non-issue. Only the exts that directly examine PG(safe_mode) and attempt to call the check uid methods will have to do any migration work which they can each apply with some well placed ifdefs.
Btw, are we getting an APINO bump with this change?Do we need one? HEAD is one huge API_NO change and we are still making lots of huge Unicode API changes in the coming week or so. Not that I mind doing it but I don't think it'll help ;) Thanks for the quick response. Andi