Re: Re: PHP (anti) crash policy?
| From: | Olaf van der Spek | Date: | Mon, 04 Oct 2004 10:02:03 +0000 |
| Subject: | Re: Re: PHP (anti) crash policy? | ||
| References: | 1 2 3 4 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-198580@lists.php.net to get a copy of this message | ||
David Bevan wrote:
On October 3, 2004 12:46, Olaf van der Spek wrote:Because I don't have time to fix every bug (I encounter) in every open source app I use. And I don't know the internals of the PHP code to be sure my patch works and doesn't break anything else.Manuel Lemos wrote:Olaf, PHP is an open source language is it not? Since you're so smart why don't YOU write the code?Hello, On 10/03/2004 12:27 PM, Olaf Van Der Spek wrote:Why? I think a large number of data handling functions would benefit from such a function. And it'd make PHP more robust.I find it hard to justify such functionI think that making all failed memory allocations recoverable is not viable because more PHP C code that makes memory allocations assumes it only returns if it succeeds. Trying to change that everywhere memory is allocated is and monster job that I doubt that any PHP core developer will agree on doing.You could just create a new function for that: alloc_no_exception There's no need to change every call, you'd only need to change the calls that can take a NULL result.