Segmentation fault using curl_exec (php5, apache2)
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
curl (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
I reproduced this problem on 2 very different computers.
Running this simple php script makes apache to seg fault :
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'http://
curl_setopt($ch, CURLOPT_
curl_setopt($ch, CURLOPT_
curl_setopt($ch, CURLOPT_
echo(curl_
curl_close($ch);
Here is the trace I get :
fstat(48, {st_mode=
fstat(48, {st_mode=
fstat(48, {st_mode=
fstat(48, {st_mode=
mmap(NULL, 418, PROT_READ, MAP_SHARED, 48, 0) = 0x7fdac3b1f000
munmap(
close(48) = 0
stat("/
open("/
flock(48, LOCK_EX|LOCK_NB) = 0
fstat(48, {st_mode=
mmap(NULL, 4096, PROT_READ|
write(48, "version: 1\ncreator: xdebug 2.1.2"..., 115) = 115
write(48, "fl=php:
write(48, "10 40\n\n", 7) = 7
write(48, "fl=php:
write(48, "11 5\n\n", 6) = 6
write(48, "fl=php:
write(48, "12 0\n\n", 6) = 6
write(48, "fl=php:
write(48, "13 0\n\n", 6) = 6
write(48, "fl=php:
write(48, "14 0\n\n", 6) = 6
--- SIGSEGV (Segmentation fault) @ 0 (0) ---
chdir("
rt_sigaction(
kill(6982, SIGSEGV) = 0
rt_sigreturn(
--- SIGSEGV (Segmentation fault) @ 0 (0) ---
Here are binary versions
Ubuntu 11.10
PHP 5.3.6-13ubuntu3.2 with Suhosin-Patch (cli) (built: Oct 13 2011 23:09:42)
Server version: Apache/2.2.20 (Ubuntu)
curl 7.21.6 (x86_64-
Regards
Laurent
EDIT : forgot to mention, same script works just fine launched in cli.
---
ApportVersion: 1.23-0ubuntu3
Architecture: amd64
DistroRelease: Ubuntu 11.10
InstallationMedia: Kubuntu 10.04 LTS "Lucid Lynx" - Release amd64 (20100427)
NonfreeKernelMo
Package: curl 7.21.6-3ubuntu3
PackageArchitec
ProcEnviron:
LANGUAGE=
LANG=fr_FR.UTF-8
SHELL=/bin/bash
ProcVersionSign
Tags: oneiric
Uname: Linux 3.0.0-12-generic x86_64
UpgradeStatus: Upgraded to oneiric on 2011-10-15 (16 days ago)
UserGroups: adm admin cdrom dialout lp lpadmin netdev plugdev sambashare www-data
description: | updated |
Changed in curl (Ubuntu): | |
status: | Incomplete → New |
Not able to reproduce the fault. The script works fine on my Oneiric. I am using php5-suhosin 0.9.32.1-1.
To make the situation simpler, could you reproduce the crash by fetching a page from local server, like http:// 127.0.0. 1?