From bee0ea1cf58e1dd7ca9221105ddade3d5b4ddcbe Mon Sep 17 00:00:00 2001 From: stderr64 Date: Sat, 27 Jan 2024 23:36:01 +0200 Subject: Just to make sure no more than expected amount of characters is tried to be read when handling http headers --- cwebhook.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'cwebhook.c') diff --git a/cwebhook.c b/cwebhook.c index b03d752..5dd6126 100644 --- a/cwebhook.c +++ b/cwebhook.c @@ -35,10 +35,10 @@ log_file_t ldata; void safe_exit( int sigc, siginfo_t *s_info, void *ectx ){ if ( ssocket.tls_context != NULL ) SSL_CTX_free( ssocket.tls_context ); - if ( ssocket.socket_fd > 0 ) - close( ssocket.socket_fd ); if ( ssocket.client_socket_fd > 0 ) close( ssocket.client_socket_fd ); + if ( ssocket.socket_fd > 0 ) + close( ssocket.socket_fd ); if ( sconfig.config_parsed != NULL ) cJSON_Delete( sconfig.config_parsed ); if ( whinfo.webhooks_parsed != NULL ) -- cgit v1.2.3-86-g962b