From b35b31b0f88f89c4afd23b79946263926317e087 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Sun, 9 Jul 2006 17:06:35 +0000 Subject: (print_esc): Don't assume char is unsigned. --- src/printf.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/printf.c') diff --git a/src/printf.c b/src/printf.c index 8707f3e4d..2f29bc080 100644 --- a/src/printf.c +++ b/src/printf.c @@ -1,5 +1,5 @@ /* printf - format and print data - Copyright (C) 1990-2005 Free Software Foundation, Inc. + Copyright (C) 1990-2006 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -250,7 +250,7 @@ print_esc (const char *escstart, bool octal_0) { /* A hexadecimal \xhh escape sequence must have 1 or 2 hex. digits. */ for (esc_length = 0, ++p; - esc_length < 2 && ISXDIGIT (*p); + esc_length < 2 && isxdigit (to_uchar (*p)); ++esc_length, ++p) esc_value = esc_value * 16 + hextobin (*p); if (esc_length == 0) @@ -280,7 +280,7 @@ print_esc (const char *escstart, bool octal_0) esc_length > 0; --esc_length, ++p) { - if (!ISXDIGIT (*p)) + if (! isxdigit (to_uchar (*p))) error (EXIT_FAILURE, 0, _("missing hexadecimal number in escape")); uni_value = uni_value * 16 + hextobin (*p); } -- cgit v1.2.3-54-g00ecf