shithub: riscv

Download patch

ref: f52e85826f72d6ee16b167d11c85fef31399b61b
parent: 476a47b15c152e72aa8a6d9f9eb363931cbfd50f
author: cinap_lenrek <[email protected]>
date: Thu Dec 18 18:06:39 EST 2014

kernel: print addresses in hex and sizes in decimal in xallocsummary

--- a/sys/src/9/port/xalloc.c
+++ b/sys/src/9/port/xalloc.c
@@ -242,7 +242,7 @@
 
 	if(xlists.flist == nil) {
 		iunlock(&xlists);
-		print("xfree: no free holes, leaked %p bytes\n", size);
+		print("xfree: no free holes, leaked %llud bytes\n", (uvlong)size);
 		return;
 	}
 
@@ -270,8 +270,8 @@
 
 	s = 0;
 	for(h = xlists.table; h; h = h->link) {
-		print("%#p %#p %p\n", h->addr, h->top, h->size);
+		print("%#8.8p %#8.8p %llud\n", h->addr, h->top, (uvlong)h->size);
 		s += h->size;
 	}
-	print("%lld bytes free\n", (vlong)s);
+	print("%llud bytes free\n", (uvlong)s);
 }