cURL / Mailing Lists / curl-library / Single Mail

curl-library

POSTQUOTE rename on SFTP

From: Jonas Schnelli <jonas.schnelli_at_include7.ch>
Date: Sun, 30 Oct 2011 13:11:05 +0100

Hi

I try to do a kind-of atomic upload over sftp with libcurl.

Currently i'm sending a postquote command "rename" (after uploading a random uuid filename).
The rename works fine...
But when the destination file already exists, then the command fails with "rename command failed: Operation failed".

Libcurl tells libssh2 LIBSSH2_SFTP_RENAME_OVERWRITE: so, the overwrite should be possible.

I'm using curl-7.23.0-20111028
And libssh2-1.3.0

Any hints?

-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2011-10-30