geom_gate userland utility improvements
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

57 lines
2.0 KiB

  1. .TH libssh2_sftp_rename_ex 3 "1 Jun 2007" "libssh2 0.15" "libssh2 manual"
  2. .SH NAME
  3. libssh2_sftp_rename_ex - rename an SFTP file
  4. .SH SYNOPSIS
  5. #include <libssh2.h>
  6. #include <libssh2_sftp.h>
  7. int
  8. libssh2_sftp_rename_ex(LIBSSH2_SFTP *sftp, const char *source_filename, unsigned int source_filename_len, const char *dest_filename, unsigned int dest_filename_len, long flags);
  9. int
  10. libssh2_sftp_rename_ex(LIBSSH2_SFTP *sftp, const char *source_filename, const char *dest_filename);
  11. .SH DESCRIPTION
  12. \fIsftp\fP - SFTP instance as returned by
  13. .BR libssh2_sftp_init(3)
  14. \fIsourcefile\fP - Path and name of the existing filesystem entry
  15. \fIsourcefile_len\fP - Length of the path and name of the existing
  16. filesystem entry
  17. \fIdestfile\fP - Path and name of the target filesystem entry
  18. \fIdestfile_len\fP - Length of the path and name of the target
  19. filesystem entry
  20. \fIflags\fP -
  21. Bitmask flags made up of LIBSSH2_SFTP_RENAME_* constants.
  22. Rename a filesystem object on the remote filesystem. The semantics of
  23. this command typically include the ability to move a filesystem object
  24. between folders and/or filesystem mounts. If the LIBSSH2_SFTP_RENAME_OVERWRITE
  25. flag is not set and the destfile entry already exists, the operation
  26. will fail. Use of the other two flags indicate a preference (but not a
  27. requirement) for the remote end to perform an atomic rename operation
  28. and/or using native system calls when possible.
  29. .SH RETURN VALUE
  30. Return 0 on success or negative on failure. It returns
  31. LIBSSH2_ERROR_EAGAIN when it would otherwise block. While
  32. LIBSSH2_ERROR_EAGAIN is a negative number, it isn't really a failure per se.
  33. .SH ERRORS
  34. \fILIBSSH2_ERROR_ALLOC\fP - An internal memory allocation call failed.
  35. \fILIBSSH2_ERROR_SOCKET_SEND\fP - Unable to send data on socket.
  36. \fILIBSSH2_ERROR_SOCKET_TIMEOUT\fP -
  37. \fILIBSSH2_ERROR_SFTP_PROTOCOL\fP - An invalid SFTP protocol response was
  38. received on the socket, or an SFTP operation caused an errorcode to
  39. be returned by the server.
  40. .SH SEE ALSO
  41. .BR libssh2_sftp_init(3)