svn commit: r337268 - head/usr.sbin/pciconf

Konstantin Belousov kib at FreeBSD.org
Fri Aug 3 18:30:03 UTC 2018


Author: kib
Date: Fri Aug  3 18:30:02 2018
New Revision: 337268
URL: https://svnweb.freebsd.org/changeset/base/337268

Log:
  Fix word-size dumping.
  
  Sponsored by:	The FreeBSD Foundation
  MFC after:	12 days

Modified:
  head/usr.sbin/pciconf/pciconf.c

Modified: head/usr.sbin/pciconf/pciconf.c
==============================================================================
--- head/usr.sbin/pciconf/pciconf.c	Fri Aug  3 17:14:52 2018	(r337267)
+++ head/usr.sbin/pciconf/pciconf.c	Fri Aug  3 18:30:02 2018	(r337268)
@@ -1137,7 +1137,7 @@ dump_bar(const char *name, const char *reg, const char
 	case 4:
 		dd = (uint32_t *)(uintptr_t)((uintptr_t)pbm.pbm_map_base +
 		    pbm.pbm_bar_off + start * width);
-		for (a = 0; a < count; a += width) {
+		for (a = 0; a < count; a += width, dd++) {
 			res = fwrite(dd, width, 1, stdout);
 			if (res != 1) {
 				errx(1, "error writing to stdout");


More information about the svn-src-head mailing list