From 138615e1e813f28348be875e4f23dc10ac98b456 Mon Sep 17 00:00:00 2001 From: "Joseph C. Lehner" Date: Mon, 8 Feb 2016 16:05:53 +0100 Subject: [PATCH] Fix warning when building on 32-bit OSX --- tftp.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tftp.c b/tftp.c index ae5b1a2..c24f8cc 100644 --- a/tftp.c +++ b/tftp.c @@ -60,8 +60,10 @@ static const char *leafname(const char *path) static bool is_netascii(const char *str) { - for (; *str; ++str) { - if (*str < 0x20 || *str > 0x7f) { + uint8_t *p = (uint8_t*)str; + + for (; *p; ++p) { + if (*p < 0x20 || *p > 0x7f) { return false; } } -- 2.25.1