Bug #52317 [Sus->Asn]: Segmentation fault when using mail() on a rhel 4.x (only 64 bit)
| From: | johannes@php.net | Date: | Mon, 19 Jul 2010 13:08:15 +0000 |
| Subject: | Bug #52317 [Sus->Asn]: Segmentation fault when using mail() on a rhel 4.x (only 64 bit) | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-152527@lists.php.net to get a copy of this message | ||
Edit report at http://bugs.php.net/bug.php?id=52317&edit=1
ID: 52317
Updated by: johannes@php.net
Reported by: om at wysiwyg dot de
Summary: Segmentation fault when using mail() on a rhel 4.x
(only 64 bit)
-Status: Suspended
+Status: Assigned
Type: Bug
Package: Reproducible crash
Operating System: rhel4.8_x86_64
PHP Version: 5.2SVN-2010-07-12 (snap)
Assigned To: aharvey
New Comment:
Approved for 5.2 and 5.3.
Previous Comments:
------------------------------------------------------------------------
[2010-07-19 12:47:40] aharvey@php.net
Editing fail: ignore "I do find the fact it's 64-bit only
interesting,".
It's not that interesting when you think about it for two seconds. :)
------------------------------------------------------------------------
[2010-07-19 12:46:51] aharvey@php.net
Gah, missing header inclusion + older version of gcc = failure, hence
why this wasn't manifesting on RHEL 5 or recent Ubuntu versions. I do
find the fact it's 64-bit only interesting,
Fix checked into trunk. Given we're deep into the RC cycle, I'll talk
to the RMs before committing to the 5.2 and 5.3 branches, although I
think this is a pretty good candidate for both.
------------------------------------------------------------------------
[2010-07-19 12:46:46] aharvey@php.net
Automatic comment from SVN on behalf of aharvey
Revision: http://svn.php.net/viewvc/?view=revision&revision=301392
Log: Fix for bug #52317 (Segmentation fault when using mail() on a rhel
4.x (only 64
bit)).
------------------------------------------------------------------------
[2010-07-15 10:32:42] om at wysiwyg dot de
(gdb) bt
#0 0x0000003fc0571360 in strlen () from /lib64/tls/libc.so.6
#1 0x0000003fc0542e79 in vfprintf () from /lib64/tls/libc.so.6
#2 0x0000003fc0548626 in fprintf () from /lib64/tls/libc.so.6
#3 0x000000000060b902 in php_mail (to=0x2a9557f208 "om@wysiwyg.de",
subject=0x2a9557efc0 "the subject",
message=0x2a95580b28 "hello", headers=0xffffffff9557f388 <Address
0xffffffff9557f388 out of bounds>,
extra_cmd=0x0) at
/usr/local/src/php5.2-201007131430/ext/standard/mail.c:281
#4 0x000000000060b6dc in zif_mail (ht=4, return_value=0x2a9557f318,
return_value_ptr=0x0, this_ptr=0x0,
return_value_used=0) at
/usr/local/src/php5.2-201007131430/ext/standard/mail.c:180
#5 0x00000000006ee2cb in zend_do_fcall_common_helper_SPEC
(execute_data=0x7fbfffd1c0)
at /usr/local/src/php5.2-201007131430/Zend/zend_vm_execute.h:200
#6 0x00000000006f3bdb in ZEND_DO_FCALL_SPEC_CONST_HANDLER
(execute_data=0x7fbfffd1c0)
at /usr/local/src/php5.2-201007131430/Zend/zend_vm_execute.h:1740
#7 0x00000000006eddc1 in execute (op_array=0x2a9557e130)
at /usr/local/src/php5.2-201007131430/Zend/zend_vm_execute.h:92
#8 0x00000000006c747f in zend_execute_scripts (type=8, retval=0x0,
file_count=3)
at /usr/local/src/php5.2-201007131430/Zend/zend.c:1134
#9 0x0000000000671979 in php_execute_script
(primary_file=0x7fbffff890)
at /usr/local/src/php5.2-201007131430/main/main.c:2036
#10 0x0000000000741dfb in main (argc=2, argv=0x7fbffff9e8)
at /usr/local/src/php5.2-201007131430/sapi/cli/php_cli.c:1165
(gdb)
------------------------------------------------------------------------
[2010-07-15 10:15:59] om at wysiwyg dot de
sorry I forgot the testscript:
<?php
$to = 'om@wysiwyg.de';
$subject = 'test';
$message = 'test';
$headers = 'From: OM' . "\r\n" .
'Reply-To: om@wysiwyg.de' . "\r\n" .
'X-Mailer: PHP/' . phpversion();
//mail without $headers is working
//mail($to, $subject, $message);
//with $headers -> seg. fault
mail($to, $subject, $message, $headers);
?>
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/bug.php?id=52317
--
Edit this bug report at http://bugs.php.net/bug.php?id=52317&edit=1