cURL / Mailing Lists / curl-library / Single Mail

curl-library

RE: Request is getting truncated by my WAS App server

From: Cobb, Richard <Richard.Cobb_at_libertymutual.com>
Date: Wed, 11 May 2005 18:34:37 -0400

Really old, curl-7.9.2 I am attempting to go to the new version
7.13.2. So the option for the BUFFER upload is not available. I saw
that you added the feature in 2002, so I needed to go up to the next
version.

We are running AIX, I downloaded the binary version and it would not
link because it was looking for some gcc lib, glib, some kind of float
method was missing. I don't have access to gcc on this system because
they want to keep everything AIX'ish. So I downloaded the source,
ftp.c and hostip6.c would not compile. I don't need ftp so I commented
the offending code out, but I do need the hostip6.c AI_NUMERICHOST to
look up hard coded IP addresses so I could not fake that one out. I am
trying to figure out why this is missing on my AIX OS version.

 cc -DHAVE_CONFIG_H -I../include -I../lib -I../lib -g -qthreaded -c -M
hostip6.c -DPIC -o .libs/hostip6.o
"hostip6.c", line 249.16: 1506-045 (S) Undeclared identifier
AI_NUMERICHOST.
make: 1254-004 The error code from the last command is 1.

-----Original Message-----
From: curl-library-bounces_at_cool.haxx.se
[mailto:curl-library-bounces_at_cool.haxx.se] On Behalf Of Daniel Stenberg
Sent: Wednesday, May 11, 2005 6:20 PM
To: libcurl development
Subject: Re: Request is getting truncated by my WAS App server

On Wed, 11 May 2005, Cobb, Richard wrote:

> I am new to Curl and am trying to fix some old code (someone wrote
> long ago)
> that only sends the first 2k of the request. I put a scope on it and
it
> seems to be coming in with the URL and not placing the XML inside the
HTTP
> Header.

What libcurl version on what OS?

What happens when it stops? What does curl_easy_perform() return then?

> printf("%s",pTURL);
> curl_easy_setopt(localcurlHndl, CURLOPT_URL,
> "http://10.110.188.229:9080/curlGetPost/curlGetPost" );
> curl_easy_setopt(localcurlHndl, CURLOPT_POSTFIELDS,pTURL);
> curl_easy_setopt(localcurlHndl, CURLOPT_POSTFIELDSIZE,
> strlen(pTURL));
>
> curl_easy_perform(localcurlHndl);

Whoa, if you fetch the return code (and CURLOPT_ERRORMESSAGE) it might
actually tell you more about the problem.

The code looks fine to me otherwise.

> The question is do I need to use the curl_formadd to get this data
> inside
> the header?

POST data should not be and is not in the header in case, POST data is
in the
request-body. The above snippet will put the data in the request-body,
and so
will curl_formadd() and CURLOPT_HTTPPOST, but formadd makes multipart
formposts, which your current code does not.

-- 
  Commercial curl and libcurl Technical Support:
http://haxx.se/curl.html
Received on 2005-05-12