Replace CURLOPT_POSTFIELDSIZE_LARGE with CURLOPT_POSTFIELDSIZE
Also adds a more robust interface for setopt that does type checking based on the options used. This fixes one bug where a F32 was passed and interpreted as long. In many cases a U32 or S32 was passed as long, which would fail (only) on a 64bit non-windows big endian machine.
This commit is contained in:
@@ -263,7 +263,7 @@ void LLXMLRPCTransaction::Impl::init(XMLRPC_REQUEST request, bool useGzip)
|
||||
if (mRequestText)
|
||||
{
|
||||
Dout(dc::curl, "Writing " << mRequestTextSize << " bytes: \"" << libcwd::buf2str(mRequestText, mRequestTextSize) << "\".");;
|
||||
curlEasyRequest_w->setopt(CURLOPT_POSTFIELDSIZE_LARGE, (curl_off_t)mRequestTextSize);
|
||||
curlEasyRequest_w->setopt(CURLOPT_POSTFIELDSIZE, mRequestTextSize);
|
||||
curlEasyRequest_w->setoptString(CURLOPT_COPYPOSTFIELDS, mRequestText);
|
||||
}
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user