libssh: use dynbuf instead of realloc

When building lines to show for SFTP directory listings.

Closes #10778
This commit is contained in:
Daniel Stenberg 2023-03-16 12:51:23 +01:00
parent f24014c3eb
commit f7a3fae4cb
No known key found for this signature in database
GPG key ID: 5CC908FDB71E12C2
2 changed files with 19 additions and 39 deletions

View file

@ -157,8 +157,8 @@ struct ssh_conn {
#if defined(USE_LIBSSH)
char *readdir_linkPath;
size_t readdir_len, readdir_totalLen, readdir_currLen;
char *readdir_line;
size_t readdir_len;
struct dynbuf readdir_buf;
/* our variables */
unsigned kbd_state; /* 0 or 1 */
ssh_key privkey;