Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:66216 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 97886 invoked from network); 25 Feb 2013 19:36:15 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 25 Feb 2013 19:36:15 -0000 Authentication-Results: pb1.pair.com smtp.mail=bobwei9@hotmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=bobwei9@hotmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain hotmail.com designates 65.55.111.100 as permitted sender) X-PHP-List-Original-Sender: bobwei9@hotmail.com X-Host-Fingerprint: 65.55.111.100 blu0-omc2-s25.blu0.hotmail.com Windows 2000 SP4, XP SP1 Received: from [65.55.111.100] ([65.55.111.100:24696] helo=blu0-omc2-s25.blu0.hotmail.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id CD/C5-10787-D2DBB215 for ; Mon, 25 Feb 2013 14:36:13 -0500 Received: from BLU0-SMTP84 ([65.55.111.71]) by blu0-omc2-s25.blu0.hotmail.com with Microsoft SMTPSVC(6.0.3790.4675); Mon, 25 Feb 2013 11:36:11 -0800 X-EIP: [yai3n2cWFtUod42L0t+6V/S5qj2LpRH2] X-Originating-Email: [bobwei9@hotmail.com] Message-ID: Received: from bob-weinands-imac.fritz.box ([78.141.134.76]) by BLU0-SMTP84.phx.gbl over TLS secured channel with Microsoft SMTPSVC(6.0.3790.4675); Mon, 25 Feb 2013 11:36:09 -0800 Content-Type: text/plain; charset="iso-8859-1" MIME-Version: 1.0 (Mac OS X Mail 6.2 \(1499\)) Disposition-Notification-To: bobwei9@hotmail.com In-Reply-To: Date: Mon, 25 Feb 2013 20:36:07 +0100 Content-Transfer-Encoding: quoted-printable References: <1361810738.2376.74.camel@guybrush> <512BA931.7010909@sugarcrm.com> <512BB284.4060900@sugarcrm.com> To: PHP Developers Mailing List X-Mailer: Apple Mail (2.1499) X-OriginalArrivalTime: 25 Feb 2013 19:36:09.0507 (UTC) FILETIME=[5C987730:01CE138F] Subject: Re: [PHP-DEV] About restricting the recursive implicit calls From: bobwei9@hotmail.com (Bob Weinand) Forgotten to cc to internals list: Am 25.2.2013 um 19:50 schrieb Stas Malyshev : > Hi! >=20 >> You may use recursive functions (which are limited by the = memory_limit), >> but if you use recursive magics, it's a design error. This is not the = purpose >> of magics (, call_user_func(_array)?) and simply an abuse of the = language. >=20 > I think you are confusing magic functions with internal functions and > functions being called from internal functions. These are different > things. Looking at your patch, you are changing zend_call_function, > which can be called in many situations, every time engine code calls = any > function which is not from a userspace context (i.e. PHP code). = Limiting > it to any arbitrary number can (and does) break code, that's why it > wasn't done (it's not like it wasn't knows for years) and there are > extensions - like xdebug - which do introduce such limits. In any = case, > 100 is way, way too low. Hi! I quickly looked over http://lxr.php.net/search?q=3Dzend_call_function = but I didn't find any case where it may call itself recursively without "wrong" = user-input. I can increase the default limit to 1000, but if it is too high it has = exactly no sense. (Btw. you've seen that the counter is decremented just before returning = and don't assume I'd like to create a global maximum? It's only affecting = recursions...) We don't discuss about xDebug, but about integrating it into the core? Bob=