fix: io_set_ssl NULL in client_disconnect, SSL* type safety in protocol.h

This commit is contained in:
2026-07-17 10:07:03 +02:00
parent 431065976d
commit ff3e02e977
2 changed files with 4 additions and 0 deletions
+2
View File
@@ -5,6 +5,8 @@
#include <stdbool.h>
#include <stddef.h>
typedef struct ssl_st SSL;
typedef int Status;
enum NET_STATUS { STATUS_OK, STATUS_ERROR, STATUS_FINISHED, STATUS_NEXT, STATUS_CHUNK, STATUS_MANIFEST };
+2
View File
@@ -1,5 +1,6 @@
#include "transport_tcp.h"
#include "log.h"
#include "protocol.h"
#include <arpa/inet.h>
#include <openssl/ssl.h>
#include <signal.h>
@@ -152,6 +153,7 @@ void client_disconnect(Client *client) {
SSL_shutdown(client->ssl);
SSL_free(client->ssl);
client->ssl = NULL;
io_set_ssl(NULL);
}
close(client->file_descriptor);
if (client->ssh_child_pid > 0) {