Date: Wed, 11 Jul 2012 18:19:05 +0300 From: Toomas Aas <toomas.aas@raad.tartu.ee> To: freebsd-questions@freebsd.org Subject: Re: curl error: SSL_write() returned SYSCALL, errno = 32 Message-ID: <20120711181905.38805t0j3nik358o@webmail.raad.tartu.ee> In-Reply-To: <20120710160539.102922863js2qjs3@webmail.raad.tartu.ee> References: <20120710160539.102922863js2qjs3@webmail.raad.tartu.ee>
next in thread | previous in thread | raw e-mail | index | archive | help
Hello again!
> Recently I upgraded a lot of ports on one of our FreeBSD 7.4
> servers. Among others I upgraded curl from 7.19.6 to 7.24.0, and php
> from 5.2.11 to 5.3.13. PHP's curl extension is also installed.
>
> After the upgrade, an application which tries to POST some data over
> https using PHP's curl_exec() function, is having trouble.
> curl_error() returns the following after the POST request:
>
> SSL_write() returned SYSCALL, errno = 32
Some modifications in PHP code made everything happy again.
1. Removed the Expect: 100-continue HTTP header from requests sent by
curl, by adding empty Expect: header
curl_setopt($ch, CURLOPT_HTTPHEADER, array('Expect: '));
2. Made sure CURLOPT_POSTFIELDS is an url-encoded query string instead
of being a plain PHP array:
curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query($myarray));
--
Toomas Aas
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20120711181905.38805t0j3nik358o>
