Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/external/bsd/bzip2/dist bzip2: fix lint warning about wrong ...



details:   https://anonhg.NetBSD.org/src/rev/b6a1103381c7
branches:  trunk
changeset: 1023140:b6a1103381c7
user:      rillig <rillig%NetBSD.org@localhost>
date:      Fri Aug 27 17:31:48 2021 +0000

description:
bzip2: fix lint warning about wrong usage of ctype.h functions

https://sourceware.org/bugzilla/show_bug.cgi?id=28283

diffstat:

 external/bsd/bzip2/dist/bzip2.c |  6 +++---
 external/bsd/bzip2/dist/bzlib.c |  4 ++--
 2 files changed, 5 insertions(+), 5 deletions(-)

diffs (38 lines):

diff -r 9079caaf3a0b -r b6a1103381c7 external/bsd/bzip2/dist/bzip2.c
--- a/external/bsd/bzip2/dist/bzip2.c   Fri Aug 27 09:29:05 2021 +0000
+++ b/external/bsd/bzip2/dist/bzip2.c   Fri Aug 27 17:31:48 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: bzip2.c,v 1.5 2019/07/21 11:52:14 maya Exp $   */
+/*     $NetBSD: bzip2.c,v 1.6 2021/08/27 17:31:48 rillig Exp $ */
 
 
 /*-----------------------------------------------------------*/
@@ -1762,8 +1762,8 @@
          if (p[i] == 0) break;
          p += i;
          i = 0;
-         while (isspace((Int32)(p[0]))) p++;
-         while (p[i] != 0 && !isspace((Int32)(p[i]))) i++;
+         while (isspace((UChar)(p[0]))) p++;
+         while (p[i] != 0 && !isspace((UChar)(p[i]))) i++;
          if (i > 0) {
             k = i; if (k > FILE_NAME_LEN-10) k = FILE_NAME_LEN-10;
             for (j = 0; j < k; j++) tmpName[j] = p[j];
diff -r 9079caaf3a0b -r b6a1103381c7 external/bsd/bzip2/dist/bzlib.c
--- a/external/bsd/bzip2/dist/bzlib.c   Fri Aug 27 09:29:05 2021 +0000
+++ b/external/bsd/bzip2/dist/bzlib.c   Fri Aug 27 17:31:48 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: bzlib.c,v 1.4 2019/07/21 11:52:14 maya Exp $   */
+/*     $NetBSD: bzlib.c,v 1.5 2021/08/27 17:31:48 rillig Exp $ */
 
 
 /*-------------------------------------------------------------*/
@@ -1410,7 +1410,7 @@
       case 's':
          smallMode = 1; break;
       default:
-         if (isdigit((unsigned char)(*mode))) {
+         if (isdigit((UChar)(*mode))) {
             blockSize100k = *mode-BZ_HDR_0;
          }
       }



Home | Main Index | Thread Index | Old Index