cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: My first post for verification

From: Dan Fandrich <dan_at_coneharvesters.com>
Date: Thu, 27 Aug 2015 19:42:18 +0200

On Thu, Aug 27, 2015 at 06:45:22AM -0500, Ken Alverson wrote:
> Thanks for the response Dan.
>
> I am past my first issues which were user error because I was trying to use a connect only setopt that did not support the ftp protocol. When I removed it, the transfer was attempted and did work ok. However, now I want to change to using the qtemp library but I am running into an issue again.
>
> /* specify target */
> url.Format("ftp://%s//%s", csIpAddress, "QTEMP/SAVF");
> curl_easy_setopt(curl, CURLOPT_URL, url);
>
> When I specify the target in a URL as above, CURL seems to want to use the CWD command to change the current working directory and the iSeries does not allow that:
> > CWD /
> < 250-NAMEFMT set to 1.
> < 250 "/" is current directory.
> > CWD QTEMP
> < 550-Specified directory does not exist or cannot be accessed.
> < 550 Working directory not changed.
>
> * Server denied you to change to the given directory
> * Connection #0 to host hs41 left intact
> Wed Aug 26 12:44:42 2015 Access denied to remote resource
>
> I am not the one specifying the CWD's so this must be occurring with CURL itself. So how does one specify qtemp as a library to get or put files?

I don't know what qtemp is, but your description of what it's doing sounds like
it may be breaking the RFCs w.r.t. directory handling. In any case, setting the
CURLOPT_FTP_FILEMETHOD to CURLFTPMETHOD_NOCWD will probably fix this for you.

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