cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: About getting file attibutes on FTP server using libcurl

From: Dan Fandrich <dan_at_coneharvesters.com>
Date: Wed, 25 Aug 2010 22:51:26 -0700

On Thu, Aug 26, 2010 at 01:41:40PM +0800, CHEN Xiaolei A wrote:
> Our FTP server's OS is Sun Solaris, I tried option "CURLOPT_DIRLISTONLY", but it just printed the name of files. I need to get more attributes, especially for "permission" and "file type", so I think I have to parse that memory string anyway.

Once you get that list files, you can request the attributes of each one
in turn using CURLOPT_NOBODY. But if the server supports MLSD, that's
definitely the option you want.

>>> Dan
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2010-08-26