fix: initialize ssl/ssl_ctx in client_connect_ssh to prevent use-after-free
This commit is contained in:
@@ -143,5 +143,7 @@ Client *client_connect_ssh(char *destination, int port) {
|
|||||||
client->address.sin_family = AF_UNIX;
|
client->address.sin_family = AF_UNIX;
|
||||||
client->address_length = 0;
|
client->address_length = 0;
|
||||||
client->ssh_child_pid = pid;
|
client->ssh_child_pid = pid;
|
||||||
|
client->ssl = NULL;
|
||||||
|
client->ssl_ctx = NULL;
|
||||||
return client;
|
return client;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user