php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #14912 Endless Recursion in method
Submitted: 2002-01-07 11:33 UTC Modified: 2002-01-07 12:07 UTC
From: fbeyer at clickhand dot de Assigned:
Status: Not a bug Package: Class/Object related
PHP Version: 4.1.0 OS: Windows 98
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: fbeyer at clickhand dot de
New email:
PHP Version: OS:

 

 [2002-01-07 11:33 UTC] fbeyer at clickhand dot de
I'm using PHP 4.1.0 on Windows 98 with no DLL-Extensions loaded.

Accidently I wrote a class method that called itself instead of an other method:

function getText($id)
{
...
return $text; // A valid string
}

function getHTML($id)
{
return htmlentities($this->getHTML($id)); // Here is my misstake: Should be getText() instead getHTML()
}

This code causes my Apache/1.3.20 (Win32) to crash. Okay, it's my misstake as programmer but should a wrong code be able to crash the server???

Thank you guys, you do a great job!

Ferdinand Beyer
<fbeyer@clickhand.de>

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-01-07 12:07 UTC] mfischer@php.net
Yep, it crashes. See the archives for discussion on this topic.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Oct 09 19:01:26 2024 UTC