From: Christophe CURIS <[email protected]>
This information is displayed only when debug mode was enabled to
avoid confusing users.
---
src/dialog.c | 18 ++++++++++++++++--
1 file changed, 16 insertions(+), 2 deletions(-)
diff --git a/src/dialog.c b/src/dialog.c
index 6f1950f..2c2e5d3 100644
--- a/src/dialog.c
+++ b/src/dialog.c
@@ -1244,8 +1244,22 @@ void wShowInfoPanel(WScreen * scr)
{
struct mallinfo ma = mallinfo();
snprintf(buffer, sizeof(buffer),
- _("Total memory allocated: %i kB (in use: %i kB).\n"),
- (ma.arena + ma.hblkhd) / 1024, (ma.uordblks +
ma.hblkhd) / 1024);
+#ifdef DEBUG
+ _("Total memory allocated: %i kB (in
use: %i kB, %d free chunks).\n"),
+#else
+ _("Total memory allocated: %i kB (in
use: %i kB).\n"),
+#endif
+ (ma.arena + ma.hblkhd) / 1024,
+ (ma.uordblks + ma.hblkhd) / 1024
+#ifdef DEBUG
+ /*
+ * This information is representative
of the memory
+ * fragmentation. In ideal case it
should be 1, but
+ * that is never possible
+ */
+ , ma.ordblks
+#endif
+ );
strbuf = wstrappend(strbuf, buffer);
}
--
1.7.10.4
--
To unsubscribe, send mail to [email protected].