1
0
mirror of https://git.libssh.org/projects/libssh.git synced 2025-07-28 01:41:48 +03:00

src: Define MAX_BUF_SIZE globally and use it.

Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
This commit is contained in:
Joseph Southwell
2014-02-02 19:28:51 +01:00
committed by Andreas Schneider
parent eedecd0269
commit 6bbdaceaca
5 changed files with 17 additions and 5 deletions

View File

@ -545,7 +545,7 @@ int ssh_scp_read_string(ssh_scp scp, char *buffer, size_t len){
* @see ssh_scp_request_get_warning()
*/
int ssh_scp_pull_request(ssh_scp scp){
char buffer[4096] = {0};
char buffer[MAX_BUF_SIZE] = {0};
char *mode=NULL;
char *p,*tmp;
uint64_t size;
@ -642,7 +642,7 @@ int ssh_scp_pull_request(ssh_scp scp){
* the message failed, or sending it in a bad state.
*/
int ssh_scp_deny_request(ssh_scp scp, const char *reason){
char buffer[4096];
char buffer[MAX_BUF_SIZE];
int err;
if(scp==NULL)
return SSH_ERROR;