From 1eb2a0bb6580cd03f3d62bc976b7d725c9d814c6 Mon Sep 17 00:00:00 2001 From: Alexander Entinger Date: Mon, 8 Jan 2024 07:00:04 +0100 Subject: [PATCH] Adding parenthesis to macro definition prevents erroneous calculation. This fixes #79. --- src/BearSSLClient.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/BearSSLClient.h b/src/BearSSLClient.h index 1d54e5c..031cc0b 100644 --- a/src/BearSSLClient.h +++ b/src/BearSSLClient.h @@ -38,11 +38,11 @@ #else #ifndef BEAR_SSL_CLIENT_OBUF_SIZE -#define BEAR_SSL_CLIENT_OBUF_SIZE 512 + 85 +#define BEAR_SSL_CLIENT_OBUF_SIZE (512 + 85) #endif #ifndef BEAR_SSL_CLIENT_IBUF_SIZE -#define BEAR_SSL_CLIENT_IBUF_SIZE 8192 + 85 + 325 - BEAR_SSL_CLIENT_OBUF_SIZE +#define BEAR_SSL_CLIENT_IBUF_SIZE (8192 + 85 + 325 - BEAR_SSL_CLIENT_OBUF_SIZE) #endif #endif