From 7d4603e13b6c011bfde1b894f0e3a2342b4f8f81 Mon Sep 17 00:00:00 2001 From: Joachim Wiberg Date: Sun, 6 Jul 2025 03:05:22 +0200 Subject: [PATCH] Minor, simplify clang-tidy noticed this unnecessary check. Signed-off-by: Joachim Wiberg --- src/helpers.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/helpers.h b/src/helpers.h index bbae458b..5cc24585 100644 --- a/src/helpers.h +++ b/src/helpers.h @@ -120,7 +120,7 @@ static inline char *fgetval(const char *line, const char *key, char *sep) * Check if we should strip optional separator, e.g., * 'foo = bar' => '= bar' should be stripped to 'bar' */ - while (str && strchr(sep, str[0])) { + while (strchr(sep, str[0])) { ptr = strsep(&str, sep); if (!ptr) goto fail;