cURL / Mailing Lists / curl-library / Single Mail

curl-library

FTP: get error message from server

From: pcworld <0188801_at_googlemail.com>
Date: Mon, 25 Apr 2011 16:06:32 +0200

For some actions I use the CURLOPT_QUOTE option to execute specific
commands, for example to create a directory.
When an error occurs, how can I get the error message from the server?

For example the protocol log shows this:
> MKD /x
< 550 /x: File exists
* QUOT command failed with 550

I can use the CURLOPT_ERRORBUFFER option to get the latter message
("QUOT command failed with 550"), but how could I get the server
generated error message like "File exists"?

Thanks in advance for any suggestions!
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2011-04-25