1
0
mirror of https://github.com/libssh2/libssh2.git synced 2025-10-31 23:30:25 +03:00

first conversion of a malloc => buffer in the sftp handle struct

This commit is contained in:
Daniel Stenberg
2008-12-22 12:38:41 +00:00
parent 31841e7c74
commit 962a41e4ec
2 changed files with 6 additions and 15 deletions

View File

@@ -539,6 +539,11 @@ struct _LIBSSH2_SFTP_HANDLE
LIBSSH2_SFTP *sftp;
LIBSSH2_SFTP_HANDLE *prev, *next;
/* This is a pre-allocated buffer used for sending SFTP requests as the
whole thing might not get sent in one go. This buffer is used for read,
write, close and MUST thus be big enough to suit all these. */
unsigned char request_packet[SFTP_HANDLE_MAXLEN + 25];
char handle[SFTP_HANDLE_MAXLEN];
int handle_len;