aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/lib/support/string.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/lib/support/string.c')
-rw-r--r--src/core/lib/support/string.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/core/lib/support/string.c b/src/core/lib/support/string.c
index ec93303024..523e43445b 100644
--- a/src/core/lib/support/string.c
+++ b/src/core/lib/support/string.c
@@ -300,11 +300,12 @@ void *gpr_memrchr(const void *s, int c, size_t n) {
}
bool gpr_is_true(const char *s) {
+ size_t i;
if (s == NULL) {
return false;
}
static const char *truthy[] = {"yes", "true", "1"};
- for (size_t i = 0; i < GPR_ARRAY_SIZE(truthy); i++) {
+ for (i = 0; i < GPR_ARRAY_SIZE(truthy); i++) {
if (0 == gpr_stricmp(s, truthy[i])) {
return true;
}