1
0
mirror of https://github.com/libssh2/libssh2.git synced 2025-05-11 18:21:25 +03:00
libssh2/docs/libssh2_sftp_open_r.3
Viktor Szakats bf85faaa92
sftp: add open functions with custom attribute support
Before this patch, libssh2 sent hardcoded `LIBSSH2_SFTP_ATTRIBUTES`
struct on handle open. This can be problematic on some special OS,
where the file size should be known on new file creation. I added
two new functions to resolve this issue.

Patch-by: @vajdaakos on github via 

Changes compared to :
- drop attr size fixup in favour of .
- move `memcpy()` under the state where we need it.
- bump filename length type to `size_t`.
- fix filenames in documentation and other nits.

Closes 
Closes 
2023-04-13 11:35:21 +00:00

24 lines
729 B
Groff

.TH libssh2_sftp_open_r 3 "10 Apr 2023" "libssh2 1.11.0" "libssh2 manual"
.SH NAME
libssh2_sftp_open_r - convenience macro for \fIlibssh2_sftp_open_ex_r(3)\fP calls
.SH SYNOPSIS
.nf
#include <libssh2.h>
#include <libssh2_sftp.h>
LIBSSH2_SFTP_HANDLE *
libssh2_sftp_open_r(LIBSSH2_SFTP *sftp, const char *filename,
unsigned long flags,
long mode,
LIBSSH2_SFTP_ATTRIBUTES *attrs);
.fi
.SH DESCRIPTION
This is a macro defined in a public libssh2 header file that is using the
underlying function \fIlibssh2_sftp_open_ex_r(3)\fP.
.SH RETURN VALUE
See \fIlibssh2_sftp_open_ex_r(3)\fP
.SH ERRORS
See \fIlibssh2_sftp_open_ex_r(3)\fP
.SH SEE ALSO
.BR libssh2_sftp_open_ex_r(3)