Commit e36a3b5d by Richard Kenner

(yylex): Don't use unsigned comparison to also check for < 0; do it

explicitly.

From-SVN: r4257
parent e0cf078f
...@@ -1934,7 +1934,7 @@ yylex () ...@@ -1934,7 +1934,7 @@ yylex ()
#ifdef MULTIBYTE_CHARS #ifdef MULTIBYTE_CHARS
len = mbstowcs ((wchar_t *) widep, token_buffer + 1, p - token_buffer); len = mbstowcs ((wchar_t *) widep, token_buffer + 1, p - token_buffer);
if ((unsigned) len >= (p - token_buffer)) if (len < 0 || len >= (p - token_buffer))
{ {
warning ("Ignoring invalid multibyte string"); warning ("Ignoring invalid multibyte string");
len = 0; len = 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment