Remove (void) casts that are not necessary.

(Whoops.. there was an error in the script that fixed this, letting whitespaces remain on some occasions.. Fixed this now - thanks corecode)

Index: fmt.c
===================================================================
RCS file: /cvs/src/bin/ps/fmt.c,v
retrieving revision 1.5
diff -u -u -r1.5 fmt.c
--- fmt.c	19 Mar 2004 17:47:49 -0000	1.5
+++ fmt.c	24 Oct 2004 19:52:34 -0000
@@ -121,6 +121,6 @@
 	else if (strncmp(cmdpart(argv[0]), cmd, maxlen) != 0)
 		sprintf(cp, "%s (%.*s)", ap, maxlen, cmd);
 	else
-		(void) strcpy(cp, ap);
+		strcpy(cp, ap);
 	return (cp);
 }
Index: keyword.c
===================================================================
RCS file: /cvs/src/bin/ps/keyword.c,v
retrieving revision 1.11
diff -u -u -r1.11 keyword.c
--- keyword.c	29 Jul 2004 09:20:39 -0000	1.11
+++ keyword.c	24 Oct 2004 19:52:59 -0000
@@ -203,10 +203,10 @@
 			i = len;
 			sep = "\n";
 		}
-		(void) printf("%s%s", sep, p);
+		printf("%s%s", sep, p);
 		sep = " ";
 	}
-	(void) printf("\n");
+	printf("\n");
 }
 
 void
Index: print.c
===================================================================
RCS file: /cvs/src/bin/ps/print.c,v
retrieving revision 1.14
diff -u -u -r1.14 print.c
--- print.c	17 Sep 2004 17:30:42 -0000	1.14
+++ print.c	24 Oct 2004 19:52:06 -0000
@@ -79,15 +79,15 @@
 		v = vent->var;
 		if (v->flag & LJUST) {
 			if (vent->next == NULL)	/* last one */
-				(void)printf("%s", v->header);
+				printf("%s", v->header);
 			else
-				(void)printf("%-*s", v->width, v->header);
+				printf("%-*s", v->width, v->header);
 		} else
-			(void)printf("%*s", v->width, v->header);
+			printf("%*s", v->width, v->header);
 		if (vent->next != NULL)
-			(void)putchar(' ');
+			putchar(' ');
 	}
-	(void)putchar('\n');
+	putchar('\n');
 }
 
 void
@@ -101,9 +101,9 @@
 
 	if (cflag) {
 		if (ve->next == NULL)	/* last field, don't pad */
-			(void)printf("%s", KI_THREAD(k)->td_comm);
+			printf("%s", KI_THREAD(k)->td_comm);
 		else
-			(void)printf("%-*s", v->width, KI_THREAD(k)->td_comm);
+			printf("%-*s", v->width, KI_THREAD(k)->td_comm);
 		return;
 	}
 
@@ -121,24 +121,24 @@
 		/* last field */
 		if (termwidth == UNLIMITED) {
 			if (vis_env)
-				(void)printf("%s ", vis_env);
-			(void)printf("%s", vis_args);
+				printf("%s ", vis_env);
+			printf("%s", vis_args);
 		} else {
 			left = termwidth - (totwidth - v->width);
 			if (left < 1) /* already wrapped, just use std width */
 				left = v->width;
 			if ((cp = vis_env) != NULL) {
 				while (--left >= 0 && *cp)
-					(void)putchar(*cp++);
+					putchar(*cp++);
 				if (--left >= 0)
 					putchar(' ');
 			}
 			for (cp = vis_args; --left >= 0 && *cp != '\0';)
-				(void)putchar(*cp++);
+				putchar(*cp++);
 		}
 	} else
 		/* XXX env? */
-		(void)printf("%-*.*s", v->width, v->width, vis_args);
+		printf("%-*.*s", v->width, v->width, vis_args);
 	free(vis_args);
 	if (vis_env != NULL)
 		free(vis_env);
@@ -150,7 +150,7 @@
 	const VAR *v;
 
 	v = ve->var;
-	(void)printf("%-*s", v->width, KI_THREAD(k)->td_comm);
+	printf("%-*s", v->width, KI_THREAD(k)->td_comm);
 }
 
 void
@@ -160,7 +160,7 @@
 	char *s;
 
 	v = ve->var;
-	(void)printf("%-*s", v->width, (s = KI_EPROC(k)->e_login, *s) ? s : "-");
+	printf("%-*s", v->width, (s = KI_EPROC(k)->e_login, *s) ? s : "-");
 }
 
 void
@@ -234,7 +234,7 @@
 	if ((flag & P_CONTROLT) && KI_EPROC(k)->e_pgid == KI_EPROC(k)->e_tpgid)
 		*cp++ = '+';
 	*cp = '\0';
-	(void)printf("%-*s", v->width, buf);
+	printf("%-*s", v->width, buf);
 }
 
 void
@@ -243,7 +243,7 @@
 	const VAR *v;
 
 	v = ve->var;
-	(void)printf("%*d", v->width, KI_PROC(k)->p_priority);
+	printf("%*d", v->width, KI_PROC(k)->p_priority);
 }
 
 void
@@ -252,7 +252,7 @@
 	const VAR *v;
 
 	v = ve->var;
-	(void)printf("%-*s",
+	printf("%-*s",
 	    (int)v->width, user_from_uid(KI_EPROC(k)->e_ucred.cr_uid, 0));
 }
 
@@ -268,7 +268,7 @@
 	const VAR *v;
 
 	v = ve->var;
-	(void)printf("%-*s",
+	printf("%-*s",
 	    (int)v->width, user_from_uid(KI_EPROC(k)->e_ucred.cr_ruid, 0));
 }
 
@@ -288,11 +288,11 @@
 	v = ve->var;
 	dev = KI_EPROC(k)->e_tdev;
 	if (dev == NODEV)
-		(void)printf("%*s", v->width, "??");
+		printf("%*s", v->width, "??");
 	else {
-		(void)snprintf(buff, sizeof(buff),
+		snprintf(buff, sizeof(buff),
 		    "%d/%d", major(dev), minor(dev));
-		(void)printf("%*s", v->width, buff);
+		printf("%*s", v->width, buff);
 	}
 }
 
@@ -306,12 +306,12 @@
 	v = ve->var;
 	dev = KI_EPROC(k)->e_tdev;
 	if (dev == NODEV || (ttname = devname(dev, S_IFCHR)) == NULL)
-		(void)printf("%*s ", v->width-1, "??");
+		printf("%*s ", v->width-1, "??");
 	else {
 		if (strncmp(ttname, "tty", 3) == 0 ||
 		    strncmp(ttname, "cua", 3) == 0)
 			ttname += 3;
-		(void)printf("%*.*s%c", v->width-1, v->width-1, ttname,
+		printf("%*.*s%c", v->width-1, v->width-1, ttname,
 			KI_EPROC(k)->e_flag & EPROC_CTTY ? ' ' : '-');
 	}
 }
@@ -326,9 +326,9 @@
 	v = ve->var;
 	dev = KI_EPROC(k)->e_tdev;
 	if (dev == NODEV || (ttname = devname(dev, S_IFCHR)) == NULL)
-		(void)printf("%-*s", v->width, "??");
+		printf("%-*s", v->width, "??");
 	else
-		(void)printf("%-*s", v->width, ttname);
+		printf("%-*s", v->width, ttname);
 }
 
 void
@@ -343,7 +343,7 @@
 
 	v = ve->var;
 	if (!k->ki_u.u_valid) {
-		(void)printf("%-*s", v->width, "-");
+		printf("%-*s", v->width, "-");
 		return;
 	}
 
@@ -361,16 +361,16 @@
 
 	tp = localtime(&then);
 	if (!now)
-		(void)time(&now);
+		time(&now);
 	if (now - k->ki_u.u_start.tv_sec < 24 * 3600) {
-		(void)strftime(buf, sizeof(buf) - 1,
+		strftime(buf, sizeof(buf) - 1,
 		use_ampm ? "%l:%M%p" : "%k:%M  ", tp);
 	} else if (now - k->ki_u.u_start.tv_sec < 7 * 86400) {
-		(void)strftime(buf, sizeof(buf) - 1,
+		strftime(buf, sizeof(buf) - 1,
 		use_ampm ? "%a%I%p" : "%a%H  ", tp);
 	} else
-		(void)strftime(buf, sizeof(buf) - 1, "%e%b%y", tp);
-	(void)printf("%-*s", v->width, buf);
+		strftime(buf, sizeof(buf) - 1, "%e%b%y", tp);
+	printf("%-*s", v->width, buf);
 }
 
 void
@@ -382,12 +382,12 @@
 
 	v = ve->var;
 	if (!k->ki_u.u_valid) {
-		(void)printf("%-*s", v->width, "-");
+		printf("%-*s", v->width, "-");
 		return;
 	}
 	then = k->ki_u.u_start.tv_sec;
-	(void)strftime(buf, sizeof(buf) -1, "%c", localtime(&then));
-	(void)printf("%-*s", v->width, buf);
+	strftime(buf, sizeof(buf) -1, "%c", localtime(&then));
+	printf("%-*s", v->width, buf);
 }
 
 void
@@ -398,13 +398,13 @@
 	v = ve->var;
 	if (KI_THREAD(k)->td_wchan) {
 		if (KI_THREAD(k)->td_wmesg)
-			(void)printf("%-*.*s", v->width, v->width,
+			printf("%-*.*s", v->width, v->width,
 				      KI_EPROC(k)->e_wmesg);
 		else
-			(void)printf("%-*lx", v->width,
+			printf("%-*lx", v->width,
 			    (long)KI_THREAD(k)->td_wchan);
 	} else
-		(void)printf("%-*s", v->width, "-");
+		printf("%-*s", v->width, "-");
 }
 
 #ifndef pgtok
@@ -417,7 +417,7 @@
 	const VAR *v;
 
 	v = ve->var;
-	(void)printf("%*d", v->width,
+	printf("%*d", v->width,
 	    (KI_EPROC(k)->e_vm.vm_map.size/1024));
 }
 
@@ -428,7 +428,7 @@
 
 	v = ve->var;
 	/* XXX don't have info about shared */
-	(void)printf("%*lu", v->width,
+	printf("%*lu", v->width,
 	    (u_long)pgtok(KI_EPROC(k)->e_vm.vm_rssize));
 }
 
@@ -438,7 +438,7 @@
 	const VAR *v;
 
 	v = ve->var;
-	(void)printf("%*ld", v->width, (long)pgtok(KI_EPROC(k)->e_vm.vm_rssize));
+	printf("%*ld", v->width, (long)pgtok(KI_EPROC(k)->e_vm.vm_rssize));
 }
 
 void
@@ -480,9 +480,9 @@
 		secs += psecs / 100;
 		psecs = psecs % 100;
 	}
-	(void)snprintf(obuff, sizeof(obuff),
+	snprintf(obuff, sizeof(obuff),
 	    "%3ld:%02ld%c%02ld", secs/60, secs%60, decimal_point, psecs);
-	(void)printf("%*s", v->width, obuff);
+	printf("%*s", v->width, obuff);
 }
 
 double
@@ -514,7 +514,7 @@
 	const VAR *v;
 
 	v = ve->var;
-	(void)printf("%*.1f", v->width, getpcpu(k));
+	printf("%*.1f", v->width, getpcpu(k));
 }
 
 void
@@ -538,7 +538,7 @@
 		break;
 	}
 	v = ve->var;
-	(void)printf("%*d", v->width, niceval);
+	printf("%*d", v->width, niceval);
 }
 
 
@@ -573,7 +573,7 @@
 	const VAR *v;
 
 	v = ve->var;
-	(void)printf("%*.1f", v->width, getpmem(k));
+	printf("%*.1f", v->width, getpmem(k));
 }
 
 void
@@ -582,7 +582,7 @@
 	const VAR *v;
 
 	v = ve->var;
-	(void)printf("%*ld", v->width,
+	printf("%*ld", v->width,
 	    k->ki_u.u_valid ? k->ki_u.u_ru.ru_majflt : 0);
 }
 
@@ -594,7 +594,7 @@
 
 	v = ve->var;
 	/* XXX not yet */
-	(void)printf("%*s", v->width, "-");
+	printf("%*s", v->width, "-");
 }
 
 void
@@ -603,7 +603,7 @@
 	const VAR *v;
 
 	v = ve->var;
-	(void)printf("%*ld", v->width, (long)pgtok(KI_EPROC(k)->e_vm.vm_tsize));
+	printf("%*ld", v->width, (long)pgtok(KI_EPROC(k)->e_vm.vm_tsize));
 }
 
 void
@@ -633,7 +633,7 @@
 		break;
 	}
 	str[sizeof(str) - 1] = '\0';
-	(void)printf("%*s", v->width, str);
+	printf("%*s", v->width, str);
 }
 
 /*
@@ -656,31 +656,31 @@
 
 	switch (v->type) {
 	case CHAR:
-		(void)printf(ofmt, v->width, *(const char *)bp);
+		printf(ofmt, v->width, *(const char *)bp);
 		break;
 	case UCHAR:
-		(void)printf(ofmt, v->width, *(const u_char *)bp);
+		printf(ofmt, v->width, *(const u_char *)bp);
 		break;
 	case SHORT:
-		(void)printf(ofmt, v->width, *(const short *)bp);
+		printf(ofmt, v->width, *(const short *)bp);
 		break;
 	case USHORT:
-		(void)printf(ofmt, v->width, *(const u_short *)bp);
+		printf(ofmt, v->width, *(const u_short *)bp);
 		break;
 	case INT:
-		(void)printf(ofmt, v->width, *(const int *)bp);
+		printf(ofmt, v->width, *(const int *)bp);
 		break;
 	case UINT:
-		(void)printf(ofmt, v->width, *(const u_int *)bp);
+		printf(ofmt, v->width, *(const u_int *)bp);
 		break;
 	case LONG:
-		(void)printf(ofmt, v->width, *(const long *)bp);
+		printf(ofmt, v->width, *(const long *)bp);
 		break;
 	case ULONG:
-		(void)printf(ofmt, v->width, *(const u_long *)bp);
+		printf(ofmt, v->width, *(const u_long *)bp);
 		break;
 	case KPTR:
-		(void)printf(ofmt, v->width, *(const u_long *)bp);
+		printf(ofmt, v->width, *(const u_long *)bp);
 		break;
 	default:
 		errx(1, "unknown type %d", v->type);
@@ -723,7 +723,7 @@
 	if (k->ki_u.u_valid)
 		printval(((const char *)&k->ki_u + v->off), v);
 	else
-		(void)printf("%*s", v->width, "-");
+		printf("%*s", v->width, "-");
 }
 
 void
@@ -735,5 +735,5 @@
 	if (k->ki_u.u_valid)
 		printval(((const char *)&k->ki_u.u_ru + v->off), v);
 	else
-		(void)printf("%*s", v->width, "-");
+		printf("%*s", v->width, "-");
 }
Index: ps.c
===================================================================
RCS file: /cvs/src/bin/ps/ps.c,v
retrieving revision 1.12
diff -u -u -r1.12 ps.c
--- ps.c	17 Sep 2004 17:30:42 -0000	1.12
+++ ps.c	24 Oct 2004 19:51:07 -0000
@@ -126,7 +126,7 @@
 	size_t btime_size = sizeof(struct timeval);
 	size_t numcpus_size = sizeof(numcpus);
 
-	(void) setlocale(LC_ALL, "");
+	setlocale(LC_ALL, "");
 
 	if ((ioctl(STDOUT_FILENO, TIOCGWINSZ, (char *)&ws) == -1 &&
 	     ioctl(STDERR_FILENO, TIOCGWINSZ, (char *)&ws) == -1 &&
@@ -411,11 +411,11 @@
 		for (vent = vhead; vent; vent = vent->next) {
 			(vent->var->oproc)(&kinfo[i], vent);
 			if (vent->next != NULL)
-				(void)putchar(' ');
+				putchar(' ');
 		}
-		(void)putchar('\n');
+		putchar('\n');
 		if (prtheader && lineno++ == prtheader - 4) {
-			(void)putchar('\n');
+			putchar('\n');
 			printheader();
 			lineno = 0;
 		}
@@ -658,7 +658,7 @@
 	    (cp == s || (cp[-1] != 't' && cp[-1] != 'p')) &&
 	    (cp - 1 == s || cp[-2] != 't'))
 		*ns++ = 'p';
-	(void)strcpy(ns, cp);		/* and append the number */
+	strcpy(ns, cp);		/* and append the number */
 
 	return (newopts);
 }
@@ -667,7 +667,7 @@
 usage(void)
 {
 
-	(void)fprintf(stderr, "%s\n%s\n%s\n",
+	fprintf(stderr, "%s\n%s\n%s\n",
 	    "usage: ps [-aChjlmrSTuvwx] [-O|o fmt] [-p pid] [-t tty] [-U user]",
 	    "          [-M core] [-N system]",
 	    "       ps [-L]");
