cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Content-Length 0?

From: Ravi chandra padmala <neenaoffline_at_gmail.com>
Date: Sat, 24 May 2008 09:11:03 -0700

Works now, kinda
Thanks a lot

On Fri, May 23, 2008 at 8:46 PM, Dan Fandrich <dan_at_coneharvesters.com>
wrote:

> On Fri, May 23, 2008 at 07:04:44PM -0700, Ravi chandra padmala wrote:
> > http://neenaoffline.one09.net/crap/cget.c
> >
> > I am trying to get the content length before downloading the file,
> > the code above doesn't work, always shows content length as 0,
> > why is that?
>
> Three problems: One is that you're passing in an uninitialized pointer to
> curl_easy_getinfo. Two, CURLINFO_CONTENT_LENGTH_DOWNLOAD doesn't take a
> pointer to long, it takes a pointer to a double. Three, the remote web
> server doesn't provide a length for this URL, probably because it's a
> dynamically-generated directory listing.
>
> >>> Dan
> --
> http://www.MoveAnnouncer.com The web change of address
> service
> Let webmasters know that your web site has moved
>
Received on 2008-05-24