Bug #71703 [Fbk->NoF]: Segfault when CURLOPT_HTTPHEADER empty array and reset

From: Date: Sun, 10 Apr 2016 04:22:23 +0000
Subject: Bug #71703 [Fbk->NoF]: Segfault when CURLOPT_HTTPHEADER empty array and reset
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-200467@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=71703&edit=1 ID: 71703 Updated by: php-bugs@lists.php.net Reported by: giel at cyclesoftware dot nl Summary: Segfault when CURLOPT_HTTPHEADER empty array and reset -Status: Feedback +Status: No Feedback Type: Bug Package: cURL related Operating System: Ubuntu PHP Version: 7.0.3 Private report: N New Comment: No feedback was provided. The bug is being suspended because we assume that you are no longer experiencing the problem. If this is not the case and you are able to provide the information that was requested earlier, please do so and change the status of the bug back to "Re-Opened". Thank you. Previous Comments: ------------------------------------------------------------------------ [2016-03-31 18:55:57] krakjoe@php.net Thank you for this bug report. To properly diagnose the problem, we need a backtrace to see what is happening behind the scenes. To find out how to generate a backtrace, please read http://bugs.php.net/bugs-generating-backtrace.php for *NIX and http://bugs.php.net/bugs-generating-backtrace-win32.php for Win32 Once you have generated a backtrace, please submit it to this bug report and change the status back to "Open". Thank you for helping us make PHP better. I too cannot reproduce this. ------------------------------------------------------------------------ [2016-03-02 20:11:25] giel at cyclesoftware dot nl Unfortunately I cannot make the trace. I tried this again with a new build (to enable debugging). Now the segfault is gone. Must say that the segfault was during a prof-gen build. Thanks! ------------------------------------------------------------------------ [2016-03-02 17:03:30] laruence@php.net Thank you for this bug report. To properly diagnose the problem, we need a backtrace to see what is happening behind the scenes. To find out how to generate a backtrace, please read http://bugs.php.net/bugs-generating-backtrace.php for *NIX and http://bugs.php.net/bugs-generating-backtrace-win32.php for Win32 Once you have generated a backtrace, please submit it to this bug report and change the status back to "Open". Thank you for helping us make PHP better. I can not reproduce this ------------------------------------------------------------------------ [2016-03-02 16:14:40] giel at cyclesoftware dot nl Description: ------------ When the following code is executed it segfaults. Removing curl_setopt($ch, CURLOPT_HTTPHEADER, array()); fixes the problem. Test script: --------------- <?php $uri = "http://www.google.com"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $uri); curl_setopt($ch, CURLOPT_HTTPHEADER, array()); curl_setopt($ch, CURLOPT_HTTPHEADER, array( 'User-Agent:Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/45.0.2454.85 Safari/537.36',)); ?> Actual result: -------------- segfault ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=71703&edit=1

« previous php.bugs (#200467) next »