|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #24663 Message with "\n.\n" is being truncated
Submitted: 2003-07-15 07:05 UTC Modified: 2003-07-23 11:09 UTC
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:1 (100.0%)
From: faraco dot phpbugs at mailnull dot com Assigned:
Status: Closed Package: Mail related
PHP Version: 4.3.3RC2-dev, 5.0.0b2-dev OS: win32 only
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: faraco dot phpbugs at mailnull dot com
New email:
PHP Version: OS:


 [2003-07-15 07:05 UTC] faraco dot phpbugs at mailnull dot com
When a string with the character sequence "\n.\n" is passed to the message argument of mail() function, the result email is truncated just before the sequence.

Reproduce code:

$message = "Text before dot\n.\nText after dot";

mail($to, $subject, $message);


Expected result:
An email like this:

Text before dot
Text after dot

Actual result:
An email like this:

Text before dot


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2003-07-15 22:51 UTC]
Works with Linux, does not work with win32.

 [2003-07-23 11:09 UTC]
This bug has been fixed in CVS.

In case this was a PHP problem, snapshots of the sources are packaged
every three hours; this change will be in the next snapshot. You can
grab the snapshot at
In case this was a documentation problem, the fix will show up soon at

In case this was a website problem, the change will show
up on the site and on the mirror sites in short time.
Thank you for the report, and for helping us make PHP better.

PHP Copyright © 2001-2022 The PHP Group
All rights reserved.
Last updated: Sat Aug 13 06:05:43 2022 UTC