svn commit: r246319 - head/usr.bin/join

Andrew Turner andrew at FreeBSD.org
Mon Feb 4 10:05:56 UTC 2013


Author: andrew
Date: Mon Feb  4 10:05:55 2013
New Revision: 246319
URL: http://svnweb.freebsd.org/changeset/base/246319

Log:
  Cast *tabchar, a wchar_t, to a wint_t as it is the type the %lc printf
  format string expects. This is only an issue on ARM EABI where wint_t is
  different to wchar_t.

Modified:
  head/usr.bin/join/join.c

Modified: head/usr.bin/join/join.c
==============================================================================
--- head/usr.bin/join/join.c	Mon Feb  4 09:48:50 2013	(r246318)
+++ head/usr.bin/join/join.c	Mon Feb  4 10:05:55 2013	(r246319)
@@ -516,7 +516,7 @@ static void
 outfield(LINE *lp, u_long fieldno, int out_empty)
 {
 	if (needsep++)
-		(void)printf("%lc", *tabchar);
+		(void)printf("%lc", (wint_t)*tabchar);
 	if (!ferror(stdout)) {
 		if (lp->fieldcnt <= fieldno || out_empty) {
 			if (empty != NULL)


More information about the svn-src-head mailing list