cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: libcurl crash - curl_easy_perform() ???

From: Pedro Neves <pneves_at_av.it.pt>
Date: Wed, 22 Jun 2005 16:53:31 +0100

Dear Daniel,

I have tried to make a change and removed the
curl_easy_setopt(CURLOPT_WRITEDATA). As a consequence, I am not using
any files and all the output is being written to the stdout. In this
case, I have made the tests and the error is different!! Now, the
libcurl does not return and, additionally, it does not print in the
screen all the downloaded data...it stops in the middle of the download
process. Now, I am very confused with this behaviour. Probably, the http
server from the equipment has some problem. What do you think?

Regards,
Pedro Neves

Pedro Neves wrote:

>Daniel Stenberg wrote:
>
>
>
>>On Wed, 22 Jun 2005, Pedro Neves wrote:
>>
>>
>>
>>>>When you say "stops", you mean it returns before it is complete? If
>>>>so, what does curl_easy_perform() return?
>>>>
>>>>
>>>When I say "stop", it means that the curl_easy_perform() returns
>>>completely and then it does not go on to the rest of the program. To
>>>help, I paste the return code below. As you can see in the return
>>>code shown below, the reply is complete, but the program does not go
>>>on from this place (after </body></html> it stops).
>>>
>>>
>>That is not the return code in the programming sense I was referring
>>to. The HTML you get is simply downloaded data, the return code is
>>what the function returns in the function call.
>>
>>
>
>
>The curl_easy_perform() function does not even return because it stops.
>I have declared a return variable to analyse the error, but the function
>does not return when it stops. If everything goes ok, the variable res
>is filled with a zero.
>
>res = curl_easy_perform() -> however, the function does not even return
>
>
>
>
>>>I am using version 7.14.0 in Linux Ubuntu with kernel 2.6.10.
>>>
>>>
>>
>>
>>>>And you get only the partial file? How much is missing? Does it always
>>>>miss the same amount? Does it always miss a part?
>>>>
>>>>
>>>As I mentioned, it gets all the information (as you can see in the
>>>return code shown above) and then stops.
>>>
>>>
>>That sounds like a description of what libcurl does. It gets the info
>>and then returns. What else would it do?
>>
>>
>
>
>My problem is that the libcurl function is not returning. It just stops
>completely. It seems to me that it stays waiting for some information to
>jump
>out and return.
>
>
>
>>>>If you _really_ want us to help, you should make an effort to write
>>>>a small stand-alone source code example that makes your problem
>>>>appear when operating on a public URL. It would enable us to debug
>>>>and trace everything easily in our ends.
>>>>
>>>>
>>>I can provide you my code in a file. What do you think?
>>>
>>>
>>Let me emphasise: a *small* stand-alone source code. If that is what
>>you have, and it does nothing else than showing your problem, then
>>sure post it.
>>
>>But you failed to answer several of my questions, so you shouldn't
>>post anything until we have sorted out what your program does and
>>doesn't.
>>
>>
>>
>
>
>
Received on 2005-06-22