X-Git-Url: https://code.citadel.org/?a=blobdiff_plain;f=libcitadel%2Flib%2Fstringbuf.c;h=b7dc903c8e392394da2b604c9278727552098fad;hb=c89c079e5c12bf6afdfed64c7a14d1c5c793ad68;hp=ca18d0f846657c9b9d3f1d72ab4245f2f193b2a4;hpb=bb4804bc2bbd92ec8fe7dacf0405a246cb81dccf;p=citadel.git diff --git a/libcitadel/lib/stringbuf.c b/libcitadel/lib/stringbuf.c index ca18d0f84..b7dc903c8 100644 --- a/libcitadel/lib/stringbuf.c +++ b/libcitadel/lib/stringbuf.c @@ -1713,11 +1713,11 @@ int StrBufDecodeBase64(StrBuf *Buf) */ int StrBufSanitizeAscii(StrBuf *Buf, const char Mute) { - char *pch; + unsigned char *pch; if (Buf == NULL) return -1; - pch = Buf->buf; - while (pch < Buf->buf + Buf->BufUsed) { + pch = (unsigned char *)Buf->buf; + while (pch < (unsigned char *)Buf->buf + Buf->BufUsed) { if ((*pch < 0x20) || (*pch > 0x7F)) *pch = Mute; pch ++;