Module Name:    src
Committed By:   gson
Date:           Wed Apr  6 09:57:00 UTC 2016

Modified Files:
        src/usr.bin/make: arch.c parse.c str.c

Log Message:
Fully avoid the nonstandard types u_char, u_int, and u_long, which
were only used inconsistently in a few places anyway.


To generate a diff of this commit:
cvs rdiff -u -r1.68 -r1.69 src/usr.bin/make/arch.c
cvs rdiff -u -r1.213 -r1.214 src/usr.bin/make/parse.c
cvs rdiff -u -r1.35 -r1.36 src/usr.bin/make/str.c

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

Modified files:

Index: src/usr.bin/make/arch.c
diff -u src/usr.bin/make/arch.c:1.68 src/usr.bin/make/arch.c:1.69
--- src/usr.bin/make/arch.c:1.68	Thu Feb 18 18:29:14 2016
+++ src/usr.bin/make/arch.c	Wed Apr  6 09:57:00 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: arch.c,v 1.68 2016/02/18 18:29:14 christos Exp $	*/
+/*	$NetBSD: arch.c,v 1.69 2016/04/06 09:57:00 gson Exp $	*/
 
 /*
  * Copyright (c) 1988, 1989, 1990, 1993
@@ -69,14 +69,14 @@
  */
 
 #ifndef MAKE_NATIVE
-static char rcsid[] = "$NetBSD: arch.c,v 1.68 2016/02/18 18:29:14 christos Exp $";
+static char rcsid[] = "$NetBSD: arch.c,v 1.69 2016/04/06 09:57:00 gson Exp $";
 #else
 #include <sys/cdefs.h>
 #ifndef lint
 #if 0
 static char sccsid[] = "@(#)arch.c	8.2 (Berkeley) 1/2/94";
 #else
-__RCSID("$NetBSD: arch.c,v 1.68 2016/02/18 18:29:14 christos Exp $");
+__RCSID("$NetBSD: arch.c,v 1.69 2016/04/06 09:57:00 gson Exp $");
 #endif
 #endif /* not lint */
 #endif
@@ -785,7 +785,7 @@ ArchSVR4Entry(Arch *ar, char *name, size
 	    }
 	if (DEBUG(ARCH)) {
 	    fprintf(debug_file, "Found svr4 archive name table with %lu entries\n",
-	            (u_long)entry);
+	            (unsigned long)entry);
 	}
 	return 0;
     }
@@ -803,7 +803,7 @@ ArchSVR4Entry(Arch *ar, char *name, size
     if (entry >= ar->fnamesize) {
 	if (DEBUG(ARCH)) {
 	    fprintf(debug_file, "SVR4 entry offset %s is greater than %lu\n",
-		   name, (u_long)ar->fnamesize);
+		   name, (unsigned long)ar->fnamesize);
 	}
 	return 2;
     }

Index: src/usr.bin/make/parse.c
diff -u src/usr.bin/make/parse.c:1.213 src/usr.bin/make/parse.c:1.214
--- src/usr.bin/make/parse.c:1.213	Fri Mar 11 13:54:47 2016
+++ src/usr.bin/make/parse.c	Wed Apr  6 09:57:00 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: parse.c,v 1.213 2016/03/11 13:54:47 matthias Exp $	*/
+/*	$NetBSD: parse.c,v 1.214 2016/04/06 09:57:00 gson Exp $	*/
 
 /*
  * Copyright (c) 1988, 1989, 1990, 1993
@@ -69,14 +69,14 @@
  */
 
 #ifndef MAKE_NATIVE
-static char rcsid[] = "$NetBSD: parse.c,v 1.213 2016/03/11 13:54:47 matthias Exp $";
+static char rcsid[] = "$NetBSD: parse.c,v 1.214 2016/04/06 09:57:00 gson Exp $";
 #else
 #include <sys/cdefs.h>
 #ifndef lint
 #if 0
 static char sccsid[] = "@(#)parse.c	8.3 (Berkeley) 3/19/94";
 #else
-__RCSID("$NetBSD: parse.c,v 1.213 2016/03/11 13:54:47 matthias Exp $");
+__RCSID("$NetBSD: parse.c,v 1.214 2016/04/06 09:57:00 gson Exp $");
 #endif
 #endif /* not lint */
 #endif
@@ -795,11 +795,11 @@ ParseMessage(char *line)
 	return FALSE;
     }
 
-    while (isalpha((u_char)*line))
+    while (isalpha((unsigned char)*line))
 	line++;
-    if (!isspace((u_char)*line))
+    if (!isspace((unsigned char)*line))
 	return FALSE;			/* not for us */
-    while (isspace((u_char)*line))
+    while (isspace((unsigned char)*line))
 	line++;
 
     line = Var_Subst(NULL, line, VAR_CMD, VARF_WANTRES);

Index: src/usr.bin/make/str.c
diff -u src/usr.bin/make/str.c:1.35 src/usr.bin/make/str.c:1.36
--- src/usr.bin/make/str.c:1.35	Wed Feb 12 01:35:56 2014
+++ src/usr.bin/make/str.c	Wed Apr  6 09:57:00 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: str.c,v 1.35 2014/02/12 01:35:56 sjg Exp $	*/
+/*	$NetBSD: str.c,v 1.36 2016/04/06 09:57:00 gson Exp $	*/
 
 /*-
  * Copyright (c) 1988, 1989, 1990, 1993
@@ -69,14 +69,14 @@
  */
 
 #ifndef MAKE_NATIVE
-static char rcsid[] = "$NetBSD: str.c,v 1.35 2014/02/12 01:35:56 sjg Exp $";
+static char rcsid[] = "$NetBSD: str.c,v 1.36 2016/04/06 09:57:00 gson Exp $";
 #else
 #include <sys/cdefs.h>
 #ifndef lint
 #if 0
 static char     sccsid[] = "@(#)str.c	5.8 (Berkeley) 6/1/90";
 #else
-__RCSID("$NetBSD: str.c,v 1.35 2014/02/12 01:35:56 sjg Exp $");
+__RCSID("$NetBSD: str.c,v 1.36 2016/04/06 09:57:00 gson Exp $");
 #endif
 #endif				/* not lint */
 #endif
@@ -102,7 +102,7 @@ str_concat(const char *s1, const char *s
 	len2 = strlen(s2);
 
 	/* allocate length plus separator plus EOS */
-	result = bmake_malloc((u_int)(len1 + len2 + 2));
+	result = bmake_malloc((unsigned int)(len1 + len2 + 2));
 
 	/* copy first string into place */
 	memcpy(result, s1, len1);

Reply via email to