Bug #55121 [Com]: Segfault with multipart/form-data POST / 404 request
| From: | reeze dot xia at gmail dot com | Date: | Fri, 09 Dec 2011 03:07:30 +0000 |
| Subject: | Bug #55121 [Com]: Segfault with multipart/form-data POST / 404 request | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-165753@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=55121&edit=1
ID: 55121
Comment by: reeze dot xia at gmail dot com
Reported by: nbpoole@php.net
Summary: Segfault with multipart/form-data POST / 404 request
Status: Re-Opened
Type: Bug
Package: Built-in web server
Operating System: Ubuntu 10.04.2 LTS (64-bit)
PHP Version: 5.4SVN-2011-07-03 (snap)
Assigned To: fa
Block user comment: N
Private report: N
New Comment:
To make it clear, the way to reproduce the core dump is:
$ curl --form a=b "http://localhost:8000/file.php"
$ curl --form a=b "http://localhost:8000/file-non-exist.php"
if the --enable-debug flag is enabled, cli-server will exit with a message "in
consist hashtable", normally it simply core dumped.
Previous Comments:
------------------------------------------------------------------------
[2011-12-09 02:50:26] reeze dot xia at gmail dot com
Hi, the 5.4RC3 and the trunk still have this bug.
After trace the core.
I found the SG(rfc1867_uploaded_files) did't set to NULL after sapi deactive.
when try to free the HashTable php core dumped on the next form-data post request.
So It's a one-fix.
I have attached a patch for this, patch tested on Mac OS X 10.6.7 & Redhat Linux.
------------------------------------------------------------------------
[2011-08-19 08:30:20] laruence@php.net
Automatic comment from SVN on behalf of laruence
Revision: http://svn.php.net/viewvc/?view=revision&revision=315162
Log: Fixed #55450 (Built in web server not accepting file uploads), which might break #55121
fixing(r313677)
Reopened #55121 to let somebody redone the fixing(as I can't reproduce 55121 in redhat 64-bit).
------------------------------------------------------------------------
[2011-08-19 08:29:46] laruence@php.net
This cause #55450, need redone.
btw: I can't reproduce this in Redhat Linux 64-bit
------------------------------------------------------------------------
[2011-07-26 16:12:44] fa@php.net
This bug has been fixed in SVN.
Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
For Windows:
http://windows.php.net/snapshots/
Thank you for the report, and for helping us make PHP better.
------------------------------------------------------------------------
[2011-07-25 20:18:37] nbpoole@php.net
OK. I retested again just now with the latest snapshot on both OS X and Ubuntu. No
segfaults anymore.
------------------------------------------------------------------------
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
https://bugs.php.net/bug.php?id=55121
--
Edit this bug report at https://bugs.php.net/bug.php?id=55121&edit=1