Summary: | dev-lang/php-5.3.2 segfaults on arm (strict-aliasing issue) | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Siarhei Siamashka <siarhei.siamashka> |
Component: | Current packages | Assignee: | PHP Bugs <php-bugs> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | arm |
Priority: | High | ||
Version: | unspecified | ||
Hardware: | ARM | ||
OS: | Linux | ||
URL: | http://bugs.php.net/bug.php?id=46311 | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 312775 |
Description
Siarhei Siamashka
2010-07-24 22:35:52 UTC
Actually bug 295682 *might* be caused by the same issue, but I'm not completely sure (SIGBUS instead of segfault and somewhat similar, but not precisely the same backtrace). Hence reported this issue separately. Does using the patch described upstream fix the issue for you? It wasn't clear from your report. Otherwise, thanks for digging into this. (In reply to comment #2) > Does using the patch described upstream fix the issue for you? It wasn't clear > from your report. Yes, it does fix the issue. Though it might have been better to have that problematic line changed to "zval *q = (zval *) *(--p);" (still have the cast, but do it after pointer dereference, not before). I'm not familiar with php, but this particular header file uses BEGIN_EXTERN_C macro, which implies that it might be used from C++ code sometimes. And the patch from php bugtracker fails to compile as C++ without adding the explicit cast. I've included your fix into the php-5.3.3 patch tarball. Please reopen this bug if the issue is not fixed. |