From 3c96f482d96e67291a3a7a4f7c860affbf1d3655 Mon Sep 17 00:00:00 2001 From: Andrew Turner Date: Sun, 6 Jan 2013 02:50:38 +0000 Subject: [PATCH] When WCHAR_MIN == 0 the check if a wchar_t value will always be true. In this case skip the test as gcc complains it is always true. --- bin/ls/util.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/bin/ls/util.c b/bin/ls/util.c index a50eca4fbb7f..f8466cd4e046 100644 --- a/bin/ls/util.c +++ b/bin/ls/util.c @@ -184,7 +184,10 @@ prn_octal(const char *s) for (i = 0; i < (int)clen; i++) putchar((unsigned char)s[i]); len += wcwidth(wc); - } else if (goodchar && f_octal_escape && wc >= 0 && + } else if (goodchar && f_octal_escape && +#if WCHAR_MIN < 0 + wc >= 0 && +#endif wc <= (wchar_t)UCHAR_MAX && (p = strchr(esc, (char)wc)) != NULL) { putchar('\\');