From f3feafb91aea5a95b4296191df42f43ac696b0cd Mon Sep 17 00:00:00 2001 From: "Roger A. Light" Date: Mon, 12 Jan 2026 21:38:12 +0000 Subject: [PATCH] Fix compiler warning --- src/proxy_v2.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/proxy_v2.c b/src/proxy_v2.c index 50de575b..eda9aa04 100644 --- a/src/proxy_v2.c +++ b/src/proxy_v2.c @@ -103,7 +103,7 @@ static int read_tlv_ssl(struct mosquitto *context, uint16_t len, bool *have_cert } while(len > 0){ - if(context->proxy.len - context->proxy.pos < sizeof(struct pp2_tlv)){ + if(context->proxy.len - context->proxy.pos < (int)sizeof(struct pp2_tlv)){ return MOSQ_ERR_INVAL; } struct pp2_tlv *tlv = (struct pp2_tlv *)(&context->proxy.buf[context->proxy.pos]); @@ -147,7 +147,7 @@ static int read_tlv_ssl(struct mosquitto *context, uint16_t len, bool *have_cert static int read_tlv(struct mosquitto *context, bool *have_certificate) { while(context->proxy.pos < context->proxy.len){ - if(context->proxy.len - context->proxy.pos < sizeof(struct pp2_tlv)){ + if(context->proxy.len - context->proxy.pos < (int)sizeof(struct pp2_tlv)){ return MOSQ_ERR_INVAL; } struct pp2_tlv *tlv = (struct pp2_tlv *)(&context->proxy.buf[context->proxy.pos]);