Re: Crashes in lex_scan at Zend/zend_language_scanner.c / BUG #52752
| From: | Jani Ollikainen | Date: | Fri, 21 Dec 2012 08:41:59 +0000 |
| Subject: | Re: Crashes in lex_scan at Zend/zend_language_scanner.c / BUG #52752 | ||
| References: | 1 2 3 4 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-64401@lists.php.net to get a copy of this message | ||
Hi,
On 21.12.2012 8:15, Patrick Schaaf wrote:
APC takes a LOCK_EX in exactly one place, apc_bin_dumpfile(), which does not look to me like it's related to "include". The usage there is fishy anyway, not exactly sure, but I think the open that happens before taking LOCK_EX, will have truncated the file already, leading to the same type of problem as discussed above wrt concurrent readers.Usage is fishy, but it's small and can reproduce the error. Don't really know what code hits that in my production environment or is it even the same problem but it seems to have similar backtrace.
So, my conclusion would be that it is the code snippet above, and not any part of PHP or the kernel, that is at fault.Oh? Did I understand you correctly? If you can code PHP that crashes PHP, it's that codes fault not PHP's fault? I've always thought PHP to be high level programming language where PHP handles things for you and you can't code anything that crashes it like that with bus error? I think that it should at least gracefully exit, log error, what caused what and where. Better option would be that it just works. And if you don't see anything to be done in PHP, I think then at least documentation of include/require should have big warning explaining that PHP doesn't guarantee include/require not to crash PHP itself.