Basicly your patch does just try to automatically detect the maximum
execution depth limit, that can be manually set with xdebug or
hardened-php patch for quite a while now...
which is not bad for the average user. I personally like the patch (although
it needs some tweaking), but the idea is there.
This kind of protection was rejected before to get into core and most
probably will be rejected again...
OK, but we can't keep allowing PHP to segfault because of stack issues..
If you don't want this patch, please considere the others you mention
(Xdebug or Hardened-PHP) to go into the core.
and that your code will fail on systems where the stack is growing into
the opposite direction.
thats not a real problem.. a simple configure program can detect such
things, like:
int main(int argc, char **argv) {
if ((void*)&argc > (void*)&argv) return 0; /* stack grows up */
if ((void*)&argc < (void*)&argv) return 1; /* stack grows down */
return 3;
}
Nuno
P.S.: I already have a solution for the PCRE stack-related segfaults..
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php