|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #1901 recursive call limitation
Submitted: 1999-07-28 06:11 UTC Modified: 1999-08-07 12:25 UTC
From: gregori at datanetms dot co dot uk Assigned:
Status: Closed Package: Reproducible Crash
PHP Version: 4.0 Beta 1 OS: linux (RedHat 6)
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: gregori at datanetms dot co dot uk
New email:
PHP Version: OS:


 [1999-07-28 06:11 UTC] gregori at datanetms dot co dot uk
I guess that it's not a common thing that we are supposed to do with a script language but I think it's important to let you know ...

netscape 4.6 gave me "the document contained no data ..." with this script :

<body bgcolor="#ffffff" text="#000088">
function nothing($val) {
  if ($val <=0 ) return(0);
  nothing($val - 1);

echo "<br>simple function ... ";
echo "<br>recursive function ... ";
$debut = time();
$end = time();
echo "<center>Execution time : ".($end - $debut)."</center>";

Note : the script works fine with nothing(8191) or a smaller value. 
Note2: C++ support a such number of recursive call.

Is it important ?! I really dunno ...



Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [1999-08-07 12:25 UTC] zeev at cvs dot php dot net
PHP 4.0 (Zend) uses the stack for intensive data, rather than using
the heap.  That means that its tolerance recursive functions
is significantly lower than that of other languages.

It's relatively easy to tell Zend not to use the stack for this
data, and use the heap instead - which would greatly increase the
number of recursive functions possible - in the price of reduced
speed.  If you're interested in such a setting, let me know, we
may add a compile-time switch.
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Mar 02 21:01:29 2024 UTC