pkgsrc-WIP-changes archive

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

nss-hg: remove cast and DragonFlyBSD patches.



Module Name:	pkgsrc-wip
Committed By:	Thomas Klausner <wiz%NetBSD.org@localhost>
Pushed By:	wiz
Date:		Mon Aug 15 22:32:03 2016 +0200
Changeset:	54fac0800718d64ac9d5a7e0b89d67034cd93baa

Modified Files:
	nss-hg/distinfo
	nss-hg/patches/patch-coreconf_config.mk
Removed Files:
	nss-hg/patches/patch-cmd_fipstest_fipstest.c
	nss-hg/patches/patch-cmd_lib_basicutil.c
	nss-hg/patches/patch-coreconf_DragonFly.mk
	nss-hg/patches/patch-coreconf_arch.mk
	nss-hg/patches/patch-lib_Makefile
	nss-hg/patches/patch-lib_certdb_alg1485.c
	nss-hg/patches/patch-lib_certdb_certdb.c
	nss-hg/patches/patch-lib_certhigh_ocsp.c
	nss-hg/patches/patch-lib_dbm_src_mktemp.c
	nss-hg/patches/patch-lib_freebl_Makefile
	nss-hg/patches/patch-lib_freebl_config.mk
	nss-hg/patches/patch-lib_freebl_mpi_mpi.c
	nss-hg/patches/patch-lib_nss_nssinit.c
	nss-hg/patches/patch-lib_softoken_legacydb_lowcert.c
	nss-hg/patches/patch-lib_util_oidstring.c
	nss-hg/patches/patch-lib_util_portreg.c
	nss-hg/patches/patch-lib_util_utilpars.c

Log Message:
nss-hg: remove cast and DragonFlyBSD patches.

cast patches are not currently necessary for building,
and there is no progress in upstreaming them.

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=54fac0800718d64ac9d5a7e0b89d67034cd93baa

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 nss-hg/distinfo                                    |   19 +-
 nss-hg/patches/patch-cmd_fipstest_fipstest.c       | 1035 --------------------
 nss-hg/patches/patch-cmd_lib_basicutil.c           |   15 -
 nss-hg/patches/patch-coreconf_DragonFly.mk         |   90 --
 nss-hg/patches/patch-coreconf_arch.mk              |   15 -
 nss-hg/patches/patch-coreconf_config.mk            |   12 +-
 nss-hg/patches/patch-lib_Makefile                  |   15 -
 nss-hg/patches/patch-lib_certdb_alg1485.c          |   24 -
 nss-hg/patches/patch-lib_certdb_certdb.c           |   24 -
 nss-hg/patches/patch-lib_certhigh_ocsp.c           |   15 -
 nss-hg/patches/patch-lib_dbm_src_mktemp.c          |   15 -
 nss-hg/patches/patch-lib_freebl_Makefile           |   15 -
 nss-hg/patches/patch-lib_freebl_config.mk          |   15 -
 nss-hg/patches/patch-lib_freebl_mpi_mpi.c          |   24 -
 nss-hg/patches/patch-lib_nss_nssinit.c             |   36 -
 .../patches/patch-lib_softoken_legacydb_lowcert.c  |   24 -
 nss-hg/patches/patch-lib_util_oidstring.c          |   15 -
 nss-hg/patches/patch-lib_util_portreg.c            |   24 -
 nss-hg/patches/patch-lib_util_utilpars.c           |   15 -
 19 files changed, 2 insertions(+), 1445 deletions(-)

diffs:
diff --git a/nss-hg/distinfo b/nss-hg/distinfo
index 6245a3b..a36218b 100644
--- a/nss-hg/distinfo
+++ b/nss-hg/distinfo
@@ -3,31 +3,14 @@ $NetBSD: distinfo,v 1.5 2015/03/17 14:28:41 thomasklausner Exp $
 SHA1 (nss-3.16.5.tar.gz) = bec488835954698e7b19149a15205db299cd13de
 RMD160 (nss-3.16.5.tar.gz) = 19630a0815d69ee5959b562d7849d35d677c6329
 Size (nss-3.16.5.tar.gz) = 6429830 bytes
-SHA1 (patch-cmd_fipstest_fipstest.c) = 640b85bcb2254f7661f51caedde4a3a1cdbfbdfe
-SHA1 (patch-cmd_lib_basicutil.c) = cb5c0bc2e87fe815099bdfe7d1913fc919d24cad
 SHA1 (patch-cmd_shlibsign_sign.sh) = 9be9719d9e4cc212d9503616a1145b8c68b97a6a
-SHA1 (patch-coreconf_DragonFly.mk) = 328c0f3d4f03ab6d0efcfec3461d97da1c3e387a
 SHA1 (patch-coreconf_OpenBSD.mk) = 0c22a08a6024aa7505e8307e598cbd02ac569a88
 SHA1 (patch-coreconf_SunOS5.mk) = db81e955db52ccccc2dbdae364449870b9724e15
-SHA1 (patch-coreconf_arch.mk) = 5462c0620564a2ad4a0deb9d71c427e8c0d426eb
-SHA1 (patch-coreconf_config.mk) = 0fdcd3fea51ea2c250ab88197b79ae2b91f27ef5
-SHA1 (patch-lib_Makefile) = cd6f58c0ed02a93b7e6ef75c2763ee3633e453eb
-SHA1 (patch-lib_certdb_alg1485.c) = 01fc731901ff59e24723091345f09f3eb2c85956
-SHA1 (patch-lib_certdb_certdb.c) = 8636b6b53befe44e3c11a93980eecb2a440815b1
-SHA1 (patch-lib_certhigh_ocsp.c) = 7ac69dfec32d7102757133c28354dc33f762104e
-SHA1 (patch-lib_dbm_src_mktemp.c) = a23cfc9d86a91bf982bb8e27d81fc8f7391bdab8
-SHA1 (patch-lib_freebl_Makefile) = aedfd6f12872bc94256e1c6be4628334f363c2bb
+SHA1 (patch-coreconf_config.mk) = a24f2c6bbbe525f2c402e2da5e238ccc4a027c21
 SHA1 (patch-lib_freebl_blapi.h) = 00e0dcfe1f6a54bffa97c4852f9f9fcb5ab783e1
 SHA1 (patch-lib_freebl_chacha20poly1305.c) = ee99e7c04f628d285f497ae9b172a8a72da7286a
-SHA1 (patch-lib_freebl_config.mk) = ade7f656b900f93f1fdaa036a733529af132d2ca
-SHA1 (patch-lib_freebl_mpi_mpi.c) = 2d358f72da7a1fe9f257716119e5ead5ed7006ed
 SHA1 (patch-lib_freebl_sha-fast-amd64-sun.s) = 6feb56632584f04c5259dcb72e330e13d485b50a
-SHA1 (patch-lib_nss_nssinit.c) = 5caa798e9debc6991db5bde481673807e97d796d
 SHA1 (patch-lib_softoken_config.mk) = c1262775ba60facae1b00324b668dfab0eecc6c3
-SHA1 (patch-lib_softoken_legacydb_lowcert.c) = bd04607b61d9a62d43df074beb2fc9481db6e015
-SHA1 (patch-lib_util_oidstring.c) = 5017383c8f16b663792d6910b8d845b16e466ed3
-SHA1 (patch-lib_util_portreg.c) = 800b008605f60f6b909be7e973bad70c047ed91b
-SHA1 (patch-lib_util_utilpars.c) = d5fe5c344fc10c7fe1e8708a64ed082c2f536058
 SHA1 (patch-lib_zlib_gzread.c) = ee8c4cf094ccd1938a55350ad0529e0be31e0dd4
 SHA1 (patch-lib_zlib_gzwrite.c) = e094e35e7f73ddd1d24fc11de7765407e3ecff57
 SHA1 (patch-tests_libpkix_libpkix.sh) = 4df0e877ab59637fcc4b54c29b14408c73ff5105
diff --git a/nss-hg/patches/patch-cmd_fipstest_fipstest.c b/nss-hg/patches/patch-cmd_fipstest_fipstest.c
deleted file mode 100644
index 9775c90..0000000
--- a/nss-hg/patches/patch-cmd_fipstest_fipstest.c
+++ /dev/null
@@ -1,1035 +0,0 @@
-$NetBSD$
-
-Missing ctype(3) casts.
-
---- cmd/fipstest/fipstest.c.orig	2016-04-25 00:47:19.000000000 +0000
-+++ cmd/fipstest/fipstest.c
-@@ -125,7 +125,7 @@ from_hex_str(unsigned char *buf, unsigne
- 
-     /* count the hex digits */
-     nxdigit = 0;
--    for (nxdigit = 0; isxdigit(str[nxdigit]); nxdigit++) {
-+    for (nxdigit = 0; isxdigit((unsigned char)str[nxdigit]); nxdigit++) {
-         /* empty body */
-     }
-     if (nxdigit == 0) {
-@@ -333,7 +333,7 @@ tdea_kat_mmt(char *reqfn)
-         /* NumKeys */
-         if (strncmp(&buf[0], "NumKeys", 7) == 0) {
-             i = 7;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             numKeys = buf[i];
-@@ -357,10 +357,10 @@ tdea_kat_mmt(char *reqfn)
-         if (numKeys == 0) {
-             if (strncmp(buf, "KEYs", 4) == 0) {
-                 i = 4;
--                while (isspace(buf[i]) || buf[i] == '=') {
-+                while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                     i++;
-                 }
--                for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+                for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                     hex_to_byteval(&buf[i], &key[j]);
-                     key[j + 8] = key[j];
-                     key[j + 16] = key[j];
-@@ -372,10 +372,10 @@ tdea_kat_mmt(char *reqfn)
-             /* KEY1 = ... */
-             if (strncmp(buf, "KEY1", 4) == 0) {
-                 i = 4;
--                while (isspace(buf[i]) || buf[i] == '=') {
-+                while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                     i++;
-                 }
--                for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+                for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                     hex_to_byteval(&buf[i], &key[j]);
-                 }
-                 fputs(buf, resp);
-@@ -384,10 +384,10 @@ tdea_kat_mmt(char *reqfn)
-             /* KEY2 = ... */
-             if (strncmp(buf, "KEY2", 4) == 0) {
-                 i = 4;
--                while (isspace(buf[i]) || buf[i] == '=') {
-+                while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                     i++;
-                 }
--                for (j = 8; isxdigit(buf[i]); i += 2, j++) {
-+                for (j = 8; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                     hex_to_byteval(&buf[i], &key[j]);
-                 }
-                 fputs(buf, resp);
-@@ -396,10 +396,10 @@ tdea_kat_mmt(char *reqfn)
-             /* KEY3 = ... */
-             if (strncmp(buf, "KEY3", 4) == 0) {
-                 i = 4;
--                while (isspace(buf[i]) || buf[i] == '=') {
-+                while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                     i++;
-                 }
--                for (j = 16; isxdigit(buf[i]); i += 2, j++) {
-+                for (j = 16; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                     hex_to_byteval(&buf[i], &key[j]);
-                 }
-                 fputs(buf, resp);
-@@ -411,7 +411,7 @@ tdea_kat_mmt(char *reqfn)
-         if (strncmp(buf, "IV", 2) == 0) {
-             mode = NSS_DES_EDE3_CBC;
-             i = 2;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < sizeof iv; i += 2, j++) {
-@@ -428,10 +428,10 @@ tdea_kat_mmt(char *reqfn)
-                 goto loser;
-             }
-             i = 9;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &plaintext[j]);
-             }
-             plaintextlen = j;
-@@ -458,10 +458,10 @@ tdea_kat_mmt(char *reqfn)
-             }
- 
-             i = 10;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &ciphertext[j]);
-             }
-             ciphertextlen = j;
-@@ -776,7 +776,7 @@ tdea_mct(int mode, char *reqfn)
-         /* NumKeys */
-         if (strncmp(&buf[0], "NumKeys", 7) == 0) {
-             i = 7;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             numKeys = atoi(&buf[i]);
-@@ -785,10 +785,10 @@ tdea_mct(int mode, char *reqfn)
-         /* KEY1 = ... */
-         if (strncmp(buf, "KEY1", 4) == 0) {
-             i = 4;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &key[j]);
-             }
-             continue;
-@@ -796,10 +796,10 @@ tdea_mct(int mode, char *reqfn)
-         /* KEY2 = ... */
-         if (strncmp(buf, "KEY2", 4) == 0) {
-             i = 4;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 8; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 8; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &key[j]);
-             }
-             continue;
-@@ -807,10 +807,10 @@ tdea_mct(int mode, char *reqfn)
-         /* KEY3 = ... */
-         if (strncmp(buf, "KEY3", 4) == 0) {
-             i = 4;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 16; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 16; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &key[j]);
-             }
-             continue;
-@@ -819,7 +819,7 @@ tdea_mct(int mode, char *reqfn)
-         /* IV = ... */
-         if (strncmp(buf, "IV", 2) == 0) {
-             i = 2;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < sizeof iv; i += 2, j++) {
-@@ -837,7 +837,7 @@ tdea_mct(int mode, char *reqfn)
-             }
-             /* PT[0] = PT */
-             i = 9;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < sizeof plaintext; i += 2, j++) {
-@@ -860,10 +860,10 @@ tdea_mct(int mode, char *reqfn)
-             }
-             /* CT[0] = CT */
-             i = 10;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &ciphertext[j]);
-             }
- 
-@@ -1068,10 +1068,10 @@ aes_gcm(char *reqfn, int encrypt)
-         /* KEY = ... */
-         if (strncmp(buf, "Key", 3) == 0) {
-             i = 3;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &key[j]);
-             }
-             keysize = j;
-@@ -1081,7 +1081,7 @@ aes_gcm(char *reqfn, int encrypt)
-         /* IV = ... */
-         if (strncmp(buf, "IV", 2) == 0) {
-             i = 2;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < sizeof iv; i += 2, j++) {
-@@ -1098,10 +1098,10 @@ aes_gcm(char *reqfn, int encrypt)
-             }
- 
-             i = 2;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &plaintext[j]);
-             }
-             plaintextlen = j;
-@@ -1116,10 +1116,10 @@ aes_gcm(char *reqfn, int encrypt)
-             }
- 
-             i = 2;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &ciphertext[j]);
-             }
-             ciphertextlen = j;
-@@ -1128,10 +1128,10 @@ aes_gcm(char *reqfn, int encrypt)
-         }
-         if (strncmp(buf, "AAD", 3) == 0) {
-             i = 3;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &aad[j]);
-             }
-             aadlen = j;
-@@ -1180,10 +1180,10 @@ aes_gcm(char *reqfn, int encrypt)
-             }
- 
-             i = 3;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &ciphertext[j + ciphertextlen]);
-             }
-             ciphertextlen += j;
-@@ -1279,10 +1279,10 @@ aes_kat_mmt(char *reqfn)
-         /* KEY = ... */
-         if (strncmp(buf, "KEY", 3) == 0) {
-             i = 3;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &key[j]);
-             }
-             keysize = j;
-@@ -1293,7 +1293,7 @@ aes_kat_mmt(char *reqfn)
-         if (strncmp(buf, "IV", 2) == 0) {
-             mode = NSS_AES_CBC;
-             i = 2;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < sizeof iv; i += 2, j++) {
-@@ -1310,10 +1310,10 @@ aes_kat_mmt(char *reqfn)
-             }
- 
-             i = 9;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &plaintext[j]);
-             }
-             plaintextlen = j;
-@@ -1344,10 +1344,10 @@ aes_kat_mmt(char *reqfn)
-             }
- 
-             i = 10;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &ciphertext[j]);
-             }
-             ciphertextlen = j;
-@@ -1483,10 +1483,10 @@ aes_ecb_mct(char *reqfn)
-         if (strncmp(buf, "KEY", 3) == 0) {
-             /* Key[0] = Key */
-             i = 3;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &key[j]);
-             }
-             keysize = j;
-@@ -1500,7 +1500,7 @@ aes_ecb_mct(char *reqfn)
-             }
-             /* PT[0] = PT */
-             i = 9;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < sizeof plaintext; i += 2, j++) {
-@@ -1598,10 +1598,10 @@ aes_ecb_mct(char *reqfn)
-             }
-             /* CT[0] = CT */
-             i = 10;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &ciphertext[j]);
-             }
- 
-@@ -1768,10 +1768,10 @@ aes_cbc_mct(char *reqfn)
-         if (strncmp(buf, "KEY", 3) == 0) {
-             /* Key[0] = Key */
-             i = 3;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &key[j]);
-             }
-             keysize = j;
-@@ -1781,7 +1781,7 @@ aes_cbc_mct(char *reqfn)
-         if (strncmp(buf, "IV", 2) == 0) {
-             /* IV[0] = IV */
-             i = 2;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < sizeof iv; i += 2, j++) {
-@@ -1797,7 +1797,7 @@ aes_cbc_mct(char *reqfn)
-             }
-             /* PT[0] = PT */
-             i = 9;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < sizeof plaintext; i += 2, j++) {
-@@ -1909,10 +1909,10 @@ aes_cbc_mct(char *reqfn)
-             }
-             /* CT[0] = CT */
-             i = 10;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &ciphertext[j]);
-             }
- 
-@@ -2535,7 +2535,7 @@ ecdsa_pkv_test(char *reqfn)
-         if (strncmp(buf, "Qx", 2) == 0) {
-             fputs(buf, ecdsaresp);
-             i = 2;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             keyvalid = from_hex_str(&pubkey.data[1], len, &buf[i]);
-@@ -2549,7 +2549,7 @@ ecdsa_pkv_test(char *reqfn)
-                 continue;
-             }
-             i = 2;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             keyvalid = from_hex_str(&pubkey.data[1 + len], len, &buf[i]);
-@@ -2667,10 +2667,10 @@ ecdsa_siggen_test(char *reqfn)
-             ECPrivateKey *ecpriv;
- 
-             i = 3;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &msg[j]);
-             }
-             msglen = j;
-@@ -2857,10 +2857,10 @@ ecdsa_sigver_test(char *reqfn)
-         /* Msg = ... */
-         if (strncmp(buf, "Msg", 3) == 0) {
-             i = 3;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &msg[j]);
-             }
-             msglen = j;
-@@ -2885,7 +2885,7 @@ ecdsa_sigver_test(char *reqfn)
-         if (strncmp(buf, "Qx", 2) == 0) {
-             fputs(buf, ecdsaresp);
-             i = 2;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             keyvalid = from_hex_str(&ecpub.publicValue.data[1], flen,
-@@ -2899,7 +2899,7 @@ ecdsa_sigver_test(char *reqfn)
-                 continue;
-             }
-             i = 2;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             keyvalid = from_hex_str(&ecpub.publicValue.data[1 + flen], flen,
-@@ -2921,7 +2921,7 @@ ecdsa_sigver_test(char *reqfn)
-         if (buf[0] == 'R') {
-             fputs(buf, ecdsaresp);
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             sigvalid = from_hex_str(sig, olen, &buf[i]);
-@@ -2931,7 +2931,7 @@ ecdsa_sigver_test(char *reqfn)
-         if (buf[0] == 'S') {
-             fputs(buf, ecdsaresp);
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             if (sigvalid) {
-@@ -2963,7 +2963,7 @@ loser:
- PRBool
- isblankline(char *b)
- {
--    while (isspace(*b))
-+    while (isspace((unsigned char)*b))
-         b++;
-     if ((*b == '\n') || (*b == 0)) {
-         return PR_TRUE;
-@@ -3122,7 +3122,7 @@ drbg(char *reqfn)
-         if (strncmp(buf, "[PredictionResistance", 21) == 0) {
- #ifdef HANDLE_PREDICTION_RESISTANCE
-             i = 21;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             if (strncmp(buf, "False", 5) == 0) {
-@@ -3255,11 +3255,11 @@ drbg(char *reqfn)
-             if (entropyInput) {
-                 memset(entropyInput, 0, entropyInputLen);
-                 i = 18;
--                while (isspace(buf[i]) || buf[i] == '=') {
-+                while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                     i++;
-                 }
- 
--                for (j = 0; isxdigit(buf[i]); i += 2, j++) { /*j<entropyInputLen*/
-+                for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) { /*j<entropyInputLen*/
-                     hex_to_byteval(&buf[i], &entropyInput[j]);
-                 }
-             }
-@@ -3272,10 +3272,10 @@ drbg(char *reqfn)
-             if (additionalInput) {
-                 memset(additionalInput, 0, additionalInputLen);
-                 i = 21;
--                while (isspace(buf[i]) || buf[i] == '=') {
-+                while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                     i++;
-                 }
--                for (j = 0; isxdigit(buf[i]); i += 2, j++) { /*j<additionalInputLen*/
-+                for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) { /*j<additionalInputLen*/
-                     hex_to_byteval(&buf[i], &additionalInput[j]);
-                 }
-             }
-@@ -3287,10 +3287,10 @@ drbg(char *reqfn)
-         /* Entropy input = ... */
-         if (strncmp(buf, "EntropyInput", 12) == 0) {
-             i = 12;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) { /*j<entropyInputLen*/
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) { /*j<entropyInputLen*/
-                 hex_to_byteval(&buf[i], &entropyInput[j]);
-             }
-             fputs(buf, rngresp);
-@@ -3300,10 +3300,10 @@ drbg(char *reqfn)
-         /* nouce = ... */
-         if (strncmp(buf, "Nonce", 5) == 0) {
-             i = 5;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) { /*j<nonceLen*/
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) { /*j<nonceLen*/
-                 hex_to_byteval(&buf[i], &nonce[j]);
-             }
-             fputs(buf, rngresp);
-@@ -3314,10 +3314,10 @@ drbg(char *reqfn)
-         if (strncmp(buf, "PersonalizationString", 21) == 0) {
-             if (personalizationString) {
-                 i = 21;
--                while (isspace(buf[i]) || buf[i] == '=') {
-+                while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                     i++;
-                 }
--                for (j = 0; isxdigit(buf[i]); i += 2, j++) { /*j<personalizationStringLen*/
-+                for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) { /*j<personalizationStringLen*/
-                     hex_to_byteval(&buf[i], &personalizationString[j]);
-                 }
-             }
-@@ -3330,7 +3330,7 @@ drbg(char *reqfn)
-         if (strncmp(buf, "AdditionalInput", 15) == 0) {
-             if (additionalInput) {
-                 i = 15;
--                while (isspace(buf[i]) || buf[i] == '=') {
-+                while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                     i++;
-                 }
-                 for (j = 0; isxdigit(buf[i]); i += 2, j++) { /*j<additionalInputLen*/
-@@ -3350,10 +3350,10 @@ drbg(char *reqfn)
-         /* Returned bits = ... */
-         if (strncmp(buf, "ReturnedBits", 12) == 0) {
-             i = 12;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) { /*j<additionalInputLen*/
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) { /*j<additionalInputLen*/
-                 hex_to_byteval(&buf[i], &predictedreturn_bytes[j]);
-             }
- 
-@@ -3452,7 +3452,7 @@ rng_vst(char *reqfn)
-         /* Q = ... */
-         if (buf[0] == 'Q') {
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < sizeof Q; i += 2, j++) {
-@@ -3474,7 +3474,7 @@ rng_vst(char *reqfn)
-         /* b = ... */
-         if (buf[0] == 'b') {
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             b = atoi(&buf[i]);
-@@ -3487,7 +3487,7 @@ rng_vst(char *reqfn)
-         /* XKey = ... */
-         if (strncmp(buf, "XKey", 4) == 0) {
-             i = 4;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < b / 8; i += 2, j++) {
-@@ -3499,7 +3499,7 @@ rng_vst(char *reqfn)
-         /* XSeed = ... */
-         if (strncmp(buf, "XSeed", 5) == 0) {
-             i = 5;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < b / 8; i += 2, j++) {
-@@ -3575,7 +3575,7 @@ rng_mct(char *reqfn)
-         /* Q = ... */
-         if (buf[0] == 'Q') {
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < sizeof Q; i += 2, j++) {
-@@ -3597,7 +3597,7 @@ rng_mct(char *reqfn)
-         /* b = ... */
-         if (buf[0] == 'b') {
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             b = atoi(&buf[i]);
-@@ -3610,7 +3610,7 @@ rng_mct(char *reqfn)
-         /* XKey = ... */
-         if (strncmp(buf, "XKey", 4) == 0) {
-             i = 4;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < b / 8; i += 2, j++) {
-@@ -3623,7 +3623,7 @@ rng_mct(char *reqfn)
-         if (strncmp(buf, "XSeed", 5) == 0) {
-             unsigned int k;
-             i = 5;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < b / 8; i += 2, j++) {
-@@ -3774,7 +3774,7 @@ sha_test(char *reqfn)
-         if (buf[0] == '[') {
-             if (strncmp(&buf[1], "L ", 1) == 0) {
-                 i = 2;
--                while (isspace(buf[i]) || buf[i] == '=') {
-+                while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                     i++;
-                 }
-                 MDlen = atoi(&buf[i]);
-@@ -3785,7 +3785,7 @@ sha_test(char *reqfn)
-         /* Len = Length of the Input Message Length  ... */
-         if (strncmp(buf, "Len", 3) == 0) {
-             i = 3;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             if (msg) {
-@@ -3809,7 +3809,7 @@ sha_test(char *reqfn)
-         /* MSG = ... */
-         if (strncmp(buf, "Msg", 3) == 0) {
-             i = 3;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < msgLen; i += 2, j++) {
-@@ -3833,7 +3833,7 @@ sha_test(char *reqfn)
-         /* Seed = ... */
-         if (strncmp(buf, "Seed", 4) == 0) {
-             i = 4;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < sizeof seed; i += 2, j++) {
-@@ -3951,11 +3951,11 @@ hmac_test(char *reqfn)
-     while (fgets(buf, bufSize, req) != NULL) {
-         if (strncmp(buf, "Mac", 3) == 0) {
-             i = 3;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             memset(expectedHMAC, 0, HASH_LENGTH_MAX);
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &expectedHMAC[j]);
-             }
-             if (memcmp(HMAC, expectedHMAC, TLen) != 0) {
-@@ -3981,7 +3981,7 @@ hmac_test(char *reqfn)
-         if (buf[0] == '[') {
-             if (strncmp(&buf[1], "L ", 1) == 0) {
-                 i = 2;
--                while (isspace(buf[i]) || buf[i] == '=') {
-+                while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                     i++;
-                 }
-                 /* HMACLen will get reused for Tlen */
-@@ -4009,7 +4009,7 @@ hmac_test(char *reqfn)
-         /* KLen = Length of the Input Secret Key ... */
-         if (strncmp(buf, "Klen", 4) == 0) {
-             i = 4;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             keyLen = atoi(&buf[i]); /* in bytes */
-@@ -4019,7 +4019,7 @@ hmac_test(char *reqfn)
-         /* key = the secret key for the key to MAC */
-         if (strncmp(buf, "Key", 3) == 0) {
-             i = 3;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < keyLen; i += 2, j++) {
-@@ -4030,7 +4030,7 @@ hmac_test(char *reqfn)
-         /* TLen = Length of the calculated HMAC */
-         if (strncmp(buf, "Tlen", 4) == 0) {
-             i = 4;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             TLen = atoi(&buf[i]); /* in bytes */
-@@ -4040,7 +4040,7 @@ hmac_test(char *reqfn)
-         /* MSG = to HMAC always 128 bytes for these tests */
-         if (strncmp(buf, "Msg", 3) == 0) {
-             i = 3;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < msgLen; i += 2, j++) {
-@@ -4320,7 +4320,7 @@ dsa_pqgver_test(char *reqfn)
-         /* P = ... */
-         if (buf[0] == 'P') {
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < pqg.prime.len; i += 2, j++) {
-@@ -4334,7 +4334,7 @@ dsa_pqgver_test(char *reqfn)
-         /* Q = ... */
-         if (buf[0] == 'Q') {
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < pqg.subPrime.len; i += 2, j++) {
-@@ -4352,7 +4352,7 @@ dsa_pqgver_test(char *reqfn)
-                 SECITEM_ZfreeItem(&pqg.base, PR_FALSE);
-             }
-             SECITEM_AllocItem(NULL, &pqg.base, pghSize);
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < pqg.base.len; i += 2, j++) {
-@@ -4374,10 +4374,10 @@ dsa_pqgver_test(char *reqfn)
-             i = 0;
-         }
-         if (i) {
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &vfy.seed.data[j]);
-             }
-             vfy.seed.len = j;
-@@ -4402,10 +4402,10 @@ dsa_pqgver_test(char *reqfn)
-         if ((strncmp(buf, "pseed", 5) == 0) ||
-             (strncmp(buf, "qseed", 5) == 0)) {
-             i = 5;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = vfy.seed.len; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = vfy.seed.len; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &vfy.seed.data[j]);
-             }
-             vfy.seed.len = j;
-@@ -4415,7 +4415,7 @@ dsa_pqgver_test(char *reqfn)
-         }
-         if (strncmp(buf, "index", 4) == 0) {
-             i = 5;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             hex_to_byteval(&buf[i], &vfy.h.data[0]);
-@@ -4482,10 +4482,10 @@ dsa_pqgver_test(char *reqfn)
-             SECStatus rv, result = SECFailure;
- 
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &vfy.h.data[j]);
-             }
-             vfy.h.len = j;
-@@ -4834,10 +4834,10 @@ dsa_siggen_test(char *reqfn)
-             memset(sig, 0, sizeof sig);
- 
-             i = 3;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &msg[j]);
-             }
-             if (fips_hashBuf(hashType, hashBuf, msg, j) != SECSuccess) {
-@@ -4979,7 +4979,7 @@ dsa_sigver_test(char *reqfn)
-         /* P = ... */
-         if (buf[0] == 'P') {
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             memset(pubkey.params.prime.data, 0, pubkey.params.prime.len);
-@@ -4994,7 +4994,7 @@ dsa_sigver_test(char *reqfn)
-         /* Q = ... */
-         if (buf[0] == 'Q') {
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             memset(pubkey.params.subPrime.data, 0, pubkey.params.subPrime.len);
-@@ -5009,7 +5009,7 @@ dsa_sigver_test(char *reqfn)
-         /* G = ... */
-         if (buf[0] == 'G') {
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             memset(pubkey.params.base.data, 0, pubkey.params.base.len);
-@@ -5032,10 +5032,10 @@ dsa_sigver_test(char *reqfn)
-             }
- 
-             i = 3;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &msg[j]);
-             }
-             if (fips_hashBuf(hashType, hashBuf, msg, j) != SECSuccess) {
-@@ -5051,7 +5051,7 @@ dsa_sigver_test(char *reqfn)
-         /* Y = ... */
-         if (buf[0] == 'Y') {
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             memset(pubkey.publicValue.data, 0, pubkey.params.subPrime.len);
-@@ -5067,7 +5067,7 @@ dsa_sigver_test(char *reqfn)
-         if (buf[0] == 'R') {
-             memset(sig, 0, sizeof sig);
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < pubkey.params.subPrime.len; i += 2, j++) {
-@@ -5086,7 +5086,7 @@ dsa_sigver_test(char *reqfn)
-             }
- 
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = pubkey.params.subPrime.len;
-@@ -5342,7 +5342,7 @@ rsa_siggen_test(char *reqfn)
-         /* SHAAlg = ... */
-         if (strncmp(buf, "SHAAlg", 6) == 0) {
-             i = 6;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             /* set the SHA Algorithm */
-@@ -5389,10 +5389,10 @@ rsa_siggen_test(char *reqfn)
-             memset(rsa_computed_signature, 0, sizeof rsa_computed_signature);
- 
-             i = 3;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
--            for (j = 0; isxdigit(buf[i]) && j < sizeof(msg); i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]) && j < sizeof(msg); i += 2, j++) {
-                 hex_to_byteval(&buf[i], &msg[j]);
-             }
-             shaLength = fips_hashLen(shaAlg);
-@@ -5519,7 +5519,7 @@ rsa_sigver_test(char *reqfn)
-         /* n = ... modulus */
-         if (buf[0] == 'n') {
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             keyvalid = from_hex_str(&rsaBlapiPublicKey.modulus.data[0],
-@@ -5537,7 +5537,7 @@ rsa_sigver_test(char *reqfn)
-         /* SHAAlg = ... */
-         if (strncmp(buf, "SHAAlg", 6) == 0) {
-             i = 6;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             /* set the SHA Algorithm */
-@@ -5571,11 +5571,11 @@ rsa_sigver_test(char *reqfn)
-             }
- 
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             /* skip leading zero's */
--            while (isxdigit(buf[i])) {
-+            while (isxdigit((unsigned char)buf[i])) {
-                 hex_to_byteval(&buf[i], &t);
-                 if (t == 0) {
-                     i += 2;
-@@ -5584,7 +5584,7 @@ rsa_sigver_test(char *reqfn)
-             }
- 
-             /* get the exponent */
--            for (j = 0; isxdigit(buf[i]) && j < sizeof data; i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]) && j < sizeof data; i += 2, j++) {
-                 hex_to_byteval(&buf[i], &data[j]);
-             }
- 
-@@ -5613,11 +5613,11 @@ rsa_sigver_test(char *reqfn)
-             memset(msg, 0, sizeof msg);
- 
-             i = 3;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
- 
--            for (j = 0; isxdigit(buf[i]) && j < sizeof msg; i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]) && j < sizeof msg; i += 2, j++) {
-                 hex_to_byteval(&buf[i], &msg[j]);
-             }
- 
-@@ -5648,11 +5648,11 @@ rsa_sigver_test(char *reqfn)
- 
-             memset(signature, 0, sizeof(signature));
-             i = 1;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
- 
--            for (j = 0; isxdigit(buf[i]) && j < sizeof signature; i += 2, j++) {
-+            for (j = 0; isxdigit((unsigned char)buf[i]) && j < sizeof signature; i += 2, j++) {
-                 hex_to_byteval(&buf[i], &signature[j]);
-             }
- 
-@@ -5853,7 +5853,7 @@ tls(char *reqfn)
-         /* pre_master_secret = ... */
-         if (strncmp(buf, "pre_master_secret", 17) == 0) {
-             i = 17;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < pms_len; i += 2, j++) {
-@@ -5865,7 +5865,7 @@ tls(char *reqfn)
-         /* serverHello_random = ... */
-         if (strncmp(buf, "serverHello_random", 18) == 0) {
-             i = 18;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < SSL3_RANDOM_LENGTH; i += 2, j++) {
-@@ -5877,7 +5877,7 @@ tls(char *reqfn)
-         /* clientHello_random = ... */
-         if (strncmp(buf, "clientHello_random", 18) == 0) {
-             i = 18;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < SSL3_RANDOM_LENGTH; i += 2, j++) {
-@@ -5889,7 +5889,7 @@ tls(char *reqfn)
-         /* server_random = ... */
-         if (strncmp(buf, "server_random", 13) == 0) {
-             i = 13;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < SSL3_RANDOM_LENGTH; i += 2, j++) {
-@@ -5905,7 +5905,7 @@ tls(char *reqfn)
-             CK_OBJECT_HANDLE master_handle;
-             CK_OBJECT_HANDLE fake_handle;
-             i = 13;
--            while (isspace(buf[i]) || buf[i] == '=') {
-+            while (isspace((unsigned char)buf[i]) || buf[i] == '=') {
-                 i++;
-             }
-             for (j = 0; j < SSL3_RANDOM_LENGTH; i += 2, j++) {
diff --git a/nss-hg/patches/patch-cmd_lib_basicutil.c b/nss-hg/patches/patch-cmd_lib_basicutil.c
deleted file mode 100644
index 1549fb4..0000000
--- a/nss-hg/patches/patch-cmd_lib_basicutil.c
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD$
-
-Missing ctype(3) casts.
-
---- cmd/lib/basicutil.c.orig	2016-04-25 00:47:19.000000000 +0000
-+++ cmd/lib/basicutil.c
-@@ -686,7 +686,7 @@ SECU_SECItemToHex(const SECItem *item, c
- static unsigned char
- nibble(char c)
- {
--    c = PORT_Tolower(c);
-+    c = PORT_Tolower((unsigned char)c);
-     return (c >= '0' && c <= '9') ? c - '0' :
-                                   (c >=
-                                        'a' &&
diff --git a/nss-hg/patches/patch-coreconf_DragonFly.mk b/nss-hg/patches/patch-coreconf_DragonFly.mk
deleted file mode 100644
index 7b8ee56..0000000
--- a/nss-hg/patches/patch-coreconf_DragonFly.mk
+++ /dev/null
@@ -1,90 +0,0 @@
-$NetBSD: patch-coreconf_DragonFly.mk,v 1.2 2014/10/05 20:12:38 thomasklausner Exp $
-
-Support DragonFly
-
---- coreconf/DragonFly.mk.orig	2014-09-28 13:56:04.000000000 +0000
-+++ coreconf/DragonFly.mk
-@@ -0,0 +1,83 @@
-+#
-+# The contents of this file are subject to the Mozilla Public
-+# License Version 1.1 (the "License"); you may not use this file
-+# except in compliance with the License. You may obtain a copy of
-+# the License at http://www.mozilla.org/MPL/
-+# 
-+# Software distributed under the License is distributed on an "AS
-+# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
-+# implied. See the License for the specific language governing
-+# rights and limitations under the License.
-+# 
-+# The Original Code is the Netscape security libraries.
-+# 
-+# The Initial Developer of the Original Code is Netscape
-+# Communications Corporation.  Portions created by Netscape are 
-+# Copyright (C) 1994-2000 Netscape Communications Corporation.  All
-+# Rights Reserved.
-+# 
-+# Contributor(s):
-+# 
-+# Alternatively, the contents of this file may be used under the
-+# terms of the GNU General Public License Version 2 or later (the
-+# "GPL"), in which case the provisions of the GPL are applicable 
-+# instead of those above.  If you wish to allow use of your 
-+# version of this file only under the terms of the GPL and not to
-+# allow others to use your version of this file under the MPL,
-+# indicate your decision by deleting the provisions above and
-+# replace them with the notice and other provisions required by
-+# the GPL.  If you do not delete the provisions above, a recipient
-+# may use your version of this file under either the MPL or the
-+# GPL.
-+#
-+# Config stuff for DragonFly
-+#
-+
-+include $(CORE_DEPTH)/coreconf/UNIX.mk
-+
-+DEFAULT_COMPILER	= gcc
-+CC			= gcc
-+CCC			= g++
-+RANLIB			= ranlib
-+
-+ifeq ($(OS_TEST),alpha)
-+CPU_ARCH		= alpha
-+else
-+CPU_ARCH		= x86
-+endif
-+
-+OS_CFLAGS		= $(DSO_CFLAGS) -ansi -Wall -DFREEBSD -DHAVE_STRERROR -DHAVE_BSD_FLOCK
-+
-+DSO_CFLAGS		= -fPIC
-+DSO_LDOPTS		= -shared -Wl,-soname -Wl,$(notdir $@)
-+
-+#
-+# The default implementation strategy for FreeBSD is pthreads.
-+#
-+ifndef CLASSIC_NSPR
-+USE_PTHREADS		= 1
-+DEFINES			+= -D_THREAD_SAFE -D_REENTRANT
-+OS_LIBS			+= -pthread
-+DSO_LDOPTS		+= -pthread
-+endif
-+
-+ARCH			= freebsd
-+
-+MOZ_OBJFORMAT		:= $(shell test -x /usr/bin/objformat && /usr/bin/objformat || echo aout)
-+
-+DLL_SUFFIX		= so
-+
-+ifdef LIBRUNPATH
-+DSO_LDOPTS		+= -Wl,-R$(LIBRUNPATH)
-+endif
-+
-+MKSHLIB			= $(CC) $(DSO_LDOPTS)
-+ifdef MAPFILE
-+# Add LD options to restrict exported symbols to those in the map file
-+endif
-+# Change PROCESS to put the mapfile in the correct format for this platform
-+PROCESS_MAP_FILE = cp $(LIBRARY_NAME).def $@
-+
-+G++INCLUDES		= -I/usr/include/g++
-+
-+INCLUDES		+= -I/usr/X11R6/include
diff --git a/nss-hg/patches/patch-coreconf_arch.mk b/nss-hg/patches/patch-coreconf_arch.mk
deleted file mode 100644
index c41de6b..0000000
--- a/nss-hg/patches/patch-coreconf_arch.mk
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD: patch-coreconf_arch.mk,v 1.2 2014/10/05 20:12:38 thomasklausner Exp $
-
-Support DragonFly
-
---- coreconf/arch.mk.orig	2014-09-28 13:54:02.000000000 +0000
-+++ coreconf/arch.mk
-@@ -113,7 +113,7 @@ endif
- # IRIX 6.5-ALPHA-1289139620.
- #
- 
--ifeq (,$(filter-out Linux FreeBSD IRIX,$(OS_ARCH)))
-+ifeq (,$(filter-out Linux DragonFly FreeBSD IRIX,$(OS_ARCH)))
-     OS_RELEASE := $(shell echo $(OS_RELEASE) | sed 's/-.*//')
- endif
- 
diff --git a/nss-hg/patches/patch-coreconf_config.mk b/nss-hg/patches/patch-coreconf_config.mk
index 9038cbf..fb80c28 100644
--- a/nss-hg/patches/patch-coreconf_config.mk
+++ b/nss-hg/patches/patch-coreconf_config.mk
@@ -1,19 +1,9 @@
 $NetBSD: patch-coreconf_config.mk,v 1.2 2014/10/05 20:12:38 thomasklausner Exp $
 
-chunk 1: Support DragonFly
-chunk 2: Set proper dynamic library runtime search path
+Set proper dynamic library runtime search path
 
 --- coreconf/config.mk.orig	2014-09-28 13:54:02.000000000 +0000
 +++ coreconf/config.mk
-@@ -31,7 +31,7 @@ endif
- #######################################################################
- 
- TARGET_OSES = FreeBSD BSD_OS NetBSD OpenUNIX OS2 QNX Darwin BeOS OpenBSD \
--              AIX RISCOS WINNT WIN95 Linux Android
-+              AIX RISCOS WINNT WIN95 Linux Android DragonFly
- 
- ifeq (,$(filter-out $(TARGET_OSES),$(OS_TARGET)))
- include $(CORE_DEPTH)/coreconf/$(OS_TARGET).mk
 @@ -183,6 +183,7 @@ endif
  DEFINES += -DUSE_UTIL_DIRECTLY
  USE_UTIL_DIRECTLY = 1
diff --git a/nss-hg/patches/patch-lib_Makefile b/nss-hg/patches/patch-lib_Makefile
deleted file mode 100644
index 1543463..0000000
--- a/nss-hg/patches/patch-lib_Makefile
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD: patch-lib_Makefile,v 1.2 2014/10/05 20:12:38 thomasklausner Exp $
-
-Probably bogus - delete?
-
---- lib/Makefile.orig	2014-09-28 13:54:02.000000000 +0000
-+++ lib/Makefile
-@@ -38,7 +38,7 @@ endif
- 
- ifndef MOZILLA_CLIENT
- ifeq ($(OS_ARCH),Linux)
--SYSINIT_SRCDIR = sysinit  # Add the sysinit directory to DIRS.
-+#SYSINIT_SRCDIR = sysinit  # Add the sysinit directory to DIRS.
- endif
- endif
- 
diff --git a/nss-hg/patches/patch-lib_certdb_alg1485.c b/nss-hg/patches/patch-lib_certdb_alg1485.c
deleted file mode 100644
index bad73e8..0000000
--- a/nss-hg/patches/patch-lib_certdb_alg1485.c
+++ /dev/null
@@ -1,24 +0,0 @@
-$NetBSD$
-
-Missing ctype(3) casts.
-
---- lib/certdb/alg1485.c.orig	2016-01-30 10:42:11.000000000 +0000
-+++ lib/certdb/alg1485.c
-@@ -1343,7 +1343,7 @@ CERT_GetCertificateEmailAddress(CERTCert
-     }
-     if (rawEmailAddr) {
-         for (i = 0; i <= (int)PORT_Strlen(rawEmailAddr); i++) {
--            rawEmailAddr[i] = tolower(rawEmailAddr[i]);
-+            rawEmailAddr[i] = tolower((unsigned char)rawEmailAddr[i]);
-         }
-     }
- 
-@@ -1369,7 +1369,7 @@ appendStringToBuf(char* dest, char* src,
-     if (dest && src && src[0] && *pRemaining > (len = PL_strlen(src))) {
-         PRUint32 i;
-         for (i = 0; i < len; ++i)
--            dest[i] = tolower(src[i]);
-+            dest[i] = tolower((unsigned char)src[i]);
-         dest[len] = 0;
-         dest += len + 1;
-         *pRemaining -= len + 1;
diff --git a/nss-hg/patches/patch-lib_certdb_certdb.c b/nss-hg/patches/patch-lib_certdb_certdb.c
deleted file mode 100644
index e654bf5..0000000
--- a/nss-hg/patches/patch-lib_certdb_certdb.c
+++ /dev/null
@@ -1,24 +0,0 @@
-$NetBSD$
-
-Missing ctype(3) casts.
-
---- lib/certdb/certdb.c.orig	2016-01-30 10:42:11.000000000 +0000
-+++ lib/certdb/certdb.c
-@@ -1288,7 +1288,7 @@ sec_lower_string(char *s)
-     }
- 
-     while (*s) {
--        *s = PORT_Tolower(*s);
-+        *s = PORT_Tolower((unsigned char)*s);
-         s++;
-     }
- 
-@@ -2301,7 +2301,7 @@ CERT_FixupEmailAddr(const char *emailAdd
- 
-     /* make it lower case */
-     while (*str) {
--        *str = tolower(*str);
-+        *str = tolower((unsigned char)*str);
-         str++;
-     }
- 
diff --git a/nss-hg/patches/patch-lib_certhigh_ocsp.c b/nss-hg/patches/patch-lib_certhigh_ocsp.c
deleted file mode 100644
index f24f1ce..0000000
--- a/nss-hg/patches/patch-lib_certhigh_ocsp.c
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD$
-
-Missing ctype(3) casts.
-
---- lib/certhigh/ocsp.c.orig	2016-01-30 10:42:11.000000000 +0000
-+++ lib/certhigh/ocsp.c
-@@ -3569,7 +3569,7 @@ ocsp_UrlEncodeBase64Buf(const char *base
- 
-     for (walkInput = base64Buf; *walkInput; ++walkInput) {
-         char c = *walkInput;
--        if (isspace(c))
-+        if (isspace((unsigned char)c))
-             continue;
-         switch (c) {
-             case '+':
diff --git a/nss-hg/patches/patch-lib_dbm_src_mktemp.c b/nss-hg/patches/patch-lib_dbm_src_mktemp.c
deleted file mode 100644
index 43204a5..0000000
--- a/nss-hg/patches/patch-lib_dbm_src_mktemp.c
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD$
-
-Missing ctype(3) casts.
-
---- lib/dbm/src/mktemp.c.orig	2016-02-15 10:09:28.000000000 +0000
-+++ lib/dbm/src/mktemp.c
-@@ -138,7 +138,7 @@ _gettemp(char *path, register int *doope
-             if (*trv == 'z')
-                 *trv++ = 'a';
-             else {
--                if (isdigit(*trv))
-+                if (isdigit((unsigned char)*trv))
-                     *trv = 'a';
-                 else
-                     ++*trv;
diff --git a/nss-hg/patches/patch-lib_freebl_Makefile b/nss-hg/patches/patch-lib_freebl_Makefile
deleted file mode 100644
index e561777..0000000
--- a/nss-hg/patches/patch-lib_freebl_Makefile
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD: patch-lib_freebl_Makefile,v 1.2 2014/10/05 20:12:38 thomasklausner Exp $
-
-Support DragonFly
-
---- lib/freebl/Makefile.orig	2014-09-28 13:54:02.000000000 +0000
-+++ lib/freebl/Makefile
-@@ -274,7 +274,7 @@ endif
- # to bind the blapi function references in FREEBLVector vector
- # (ldvector.c) to the blapi functions defined in the freebl
- # shared libraries.
--ifeq (,$(filter-out BSD_OS FreeBSD Linux NetBSD OpenBSD, $(OS_TARGET)))
-+ifeq (,$(filter-out BSD_OS DragonFly FreeBSD Linux NetBSD OpenBSD, $(OS_TARGET)))
-     MKSHLIB += -Wl,-Bsymbolic
- endif
- 
diff --git a/nss-hg/patches/patch-lib_freebl_config.mk b/nss-hg/patches/patch-lib_freebl_config.mk
deleted file mode 100644
index 2579f92..0000000
--- a/nss-hg/patches/patch-lib_freebl_config.mk
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD: patch-lib_freebl_config.mk,v 1.2 2014/10/05 20:12:38 thomasklausner Exp $
-
-No idea, probably bogus (delete?)
-
---- lib/freebl/config.mk.orig	2014-09-28 13:54:02.000000000 +0000
-+++ lib/freebl/config.mk
-@@ -90,8 +90,4 @@ EXTRA_SHARED_LIBS += \
- endif
- endif
- 
--ifeq ($(OS_ARCH), Darwin)
--EXTRA_SHARED_LIBS += -dylib_file @executable_path/libplc4.dylib:$(DIST)/lib/libplc4.dylib -dylib_file @executable_path/libplds4.dylib:$(DIST)/lib/libplds4.dylib
--endif
--
- endif
diff --git a/nss-hg/patches/patch-lib_freebl_mpi_mpi.c b/nss-hg/patches/patch-lib_freebl_mpi_mpi.c
deleted file mode 100644
index ed27c72..0000000
--- a/nss-hg/patches/patch-lib_freebl_mpi_mpi.c
+++ /dev/null
@@ -1,24 +0,0 @@
-$NetBSD$
-
-Missing ctype(3) casts.
-
---- lib/freebl/mpi/mpi.c.orig	2016-01-30 10:42:11.000000000 +0000
-+++ lib/freebl/mpi/mpi.c
-@@ -4571,7 +4571,7 @@ int      s_mp_tovalue(char ch, int r)
-   if(r > 36)
-     xch = ch;
-   else
--    xch = toupper(ch);
-+    xch = toupper((unsigned char)ch);
- 
-   if(isdigit(xch))
-     val = xch - '0';
-@@ -4616,7 +4616,7 @@ char     s_mp_todigit(mp_digit val, int 
-   ch = s_dmap_1[val];
- 
-   if(r <= 36 && low)
--    ch = tolower(ch);
-+    ch = tolower((unsigned char)ch);
- 
-   return ch;
- 
diff --git a/nss-hg/patches/patch-lib_nss_nssinit.c b/nss-hg/patches/patch-lib_nss_nssinit.c
deleted file mode 100644
index 74cec41..0000000
--- a/nss-hg/patches/patch-lib_nss_nssinit.c
+++ /dev/null
@@ -1,36 +0,0 @@
-$NetBSD$
-
-Missing ctype(3) casts.
-
---- lib/nss/nssinit.c.orig	2016-01-30 10:42:11.000000000 +0000
-+++ lib/nss/nssinit.c
-@@ -1248,25 +1248,25 @@ NSS_VersionCheck(const char *importedVer
- #define NSS_VERSION_VARIABLE __nss_base_version
- #include "verref.h"
- 
--    while (isdigit(*ptr)) {
-+    while (isdigit((unsigned char)*ptr)) {
-         vmajor = 10 * vmajor + *ptr - '0';
-         ptr++;
-     }
-     if (*ptr == '.') {
-         ptr++;
--        while (isdigit(*ptr)) {
-+        while (isdigit((unsigned char)*ptr)) {
-             vminor = 10 * vminor + *ptr - '0';
-             ptr++;
-         }
-         if (*ptr == '.') {
-             ptr++;
--            while (isdigit(*ptr)) {
-+            while (isdigit((unsigned char)*ptr)) {
-                 vpatch = 10 * vpatch + *ptr - '0';
-                 ptr++;
-             }
-             if (*ptr == '.') {
-                 ptr++;
--                while (isdigit(*ptr)) {
-+                while (isdigit((unsigned char)*ptr)) {
-                     vbuild = 10 * vbuild + *ptr - '0';
-                     ptr++;
-                 }
diff --git a/nss-hg/patches/patch-lib_softoken_legacydb_lowcert.c b/nss-hg/patches/patch-lib_softoken_legacydb_lowcert.c
deleted file mode 100644
index 60a8af4..0000000
--- a/nss-hg/patches/patch-lib_softoken_legacydb_lowcert.c
+++ /dev/null
@@ -1,24 +0,0 @@
-$NetBSD$
-
-Missing ctype(3) casts.
-
---- lib/softoken/legacydb/lowcert.c.orig	2016-01-30 10:42:11.000000000 +0000
-+++ lib/softoken/legacydb/lowcert.c
-@@ -585,7 +585,7 @@ nsslowcert_GetCertificateEmailAddress(NS
-     /* make it lower case */
-     str = emailAddr;
-     while ( str && *str ) {
--	*str = tolower( *str );
-+	*str = tolower( (unsigned char)*str );
- 	str++;
-     }
-     return emailAddr;
-@@ -689,7 +689,7 @@ nsslowcert_FixupEmailAddr(char *emailAdd
-     
-     /* make it lower case */
-     while ( *str ) {
--	*str = tolower( *str );
-+	*str = tolower( (unsigned char)*str );
- 	str++;
-     }
-     
diff --git a/nss-hg/patches/patch-lib_util_oidstring.c b/nss-hg/patches/patch-lib_util_oidstring.c
deleted file mode 100644
index afa2cee..0000000
--- a/nss-hg/patches/patch-lib_util_oidstring.c
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD$
-
-Missing ctype(3) casts.
-
---- lib/util/oidstring.c.orig	2016-01-30 10:42:11.000000000 +0000
-+++ lib/util/oidstring.c
-@@ -50,7 +50,7 @@ bad_data:
-     }
-     do {
- 	PRUint32 decimal = 0;
--        while (len > 0 && isdigit(*from)) {
-+        while (len > 0 && isdigit((unsigned char)*from)) {
- 	    PRUint32 addend = (*from++ - '0');
- 	    --len;
- 	    if (decimal > max_decimal)  /* overflow */
diff --git a/nss-hg/patches/patch-lib_util_portreg.c b/nss-hg/patches/patch-lib_util_portreg.c
deleted file mode 100644
index f739923..0000000
--- a/nss-hg/patches/patch-lib_util_portreg.c
+++ /dev/null
@@ -1,24 +0,0 @@
-$NetBSD$
-
-Missing ctype(3) casts.
-
---- lib/util/portreg.c.orig	2016-01-30 10:42:11.000000000 +0000
-+++ lib/util/portreg.c
-@@ -277,7 +277,7 @@ _shexp_match(const char *str, const char
- 		    if (exp[y] == '\\')
- 			++y;
- 		    if(case_insensitive) {
--			matched |= (toupper(str[x]) == toupper(exp[y]));
-+			matched |= (toupper((unsigned char)str[x]) == toupper((unsigned char)exp[y]));
- 		    } else {
- 			matched |= (str[x] == exp[y]);
- 		    }
-@@ -302,7 +302,7 @@ _shexp_match(const char *str, const char
- 	    /* fall through */
- 	default:
- 	    if(case_insensitive) {
--		if(toupper(str[x]) != toupper(exp[y]))
-+		if(toupper((unsigned char)str[x]) != toupper((unsigned char)exp[y]))
- 		    return NOMATCH;
- 	    } else {
- 		if(str[x] != exp[y])
diff --git a/nss-hg/patches/patch-lib_util_utilpars.c b/nss-hg/patches/patch-lib_util_utilpars.c
deleted file mode 100644
index dba0556..0000000
--- a/nss-hg/patches/patch-lib_util_utilpars.c
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD$
-
-Missing ctype(3) casts.
-
---- lib/util/utilpars.c.orig	2016-01-30 10:42:11.000000000 +0000
-+++ lib/util/utilpars.c
-@@ -243,7 +243,7 @@ NSSUTIL_ArgDecodeNumber(const char *num)
- 
-    
-     for ( ;*num; num++ ) {
--	if (isdigit(*num)) {
-+	if (isdigit((unsigned char)*num)) {
- 	    digit = *num - '0';
- 	} else if ((*num >= 'a') && (*num <= 'f'))  {
- 	    digit = *num - 'a' + 10;


Home | Main Index | Thread Index | Old Index