cURL
Haxx ad
libcurl

curl's project page on SourceForge.net

Sponsors:
Haxx

cURL > Mailing List > Monthly Index > Single Mail

curl-library Mailing List Archives

Re: How to get current working directory of ftp?

From: Dan Fandrich <dan_at_coneharvesters.com>
Date: Mon, 18 Oct 2010 23:43:24 -0700

On Tue, Oct 19, 2010 at 10:45:50AM +0800, LIN Huangyang wrote:
> I'm using curl-7.21.0. I meet a problem that I cannot get FTP current working
> directory.
>
> When I sent FTP command "PWD", I found the directory information was printed
> out to screen as debug trace like "257 "/home/xxx" is current directory",
> instead of being processed by callback.
>
> Can I retrieve this information anywhere in memory, or by calling other
> functions? Thanks.

You can install a CURLOPT_HEADERFUNCTION and/or CURLOPT_DEBUGFUNCTION
callback to retrieve the data and process it any way you'd like.

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

These mail archives are generated by hypermail.

donate! Page updated November 12, 2010.
web site info

File upload with ASP.NET