From bfcd941a9164d81ffb7267c81f6820a20b60fd53 Mon Sep 17 00:00:00 2001 From: dovholuknf <46322585+dovholuknf@users.noreply.github.com> Date: Thu, 17 Oct 2024 13:37:48 -0400 Subject: [PATCH] fix macOS and infinite loop --- library/config.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/library/config.c b/library/config.c index 82e2c23a..9074f2c8 100644 --- a/library/config.c +++ b/library/config.c @@ -15,6 +15,7 @@ #include #include #include +#include #include "zt_internal.h" const char* APP_ID = NULL; @@ -52,7 +53,7 @@ int ziti_load_config(ziti_config *cfg, const char* cfgstr) { } bool seems_like_json = false; const char* c = cfgstr; - while (*cfgstr && isspace((unsigned char)*cfgstr)) { + while (*c && isspace((unsigned char)*c)) { c++; } if (*c == '{') {