diff options
author | in2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2003-01-15 17:41:19 +0800 |
---|---|---|
committer | in2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2003-01-15 17:41:19 +0800 |
commit | 4ec6b30667d83b998fa9cc1e18e34ee32d96affb (patch) | |
tree | b59a3fc8998c841b30424eac3aafa6ea6f5d4b68 /mbbsd/io.c | |
parent | 7a75ab531004ab812b2e58cce1998482aaad7b7d (diff) | |
download | pttbbs-4ec6b30667d83b998fa9cc1e18e34ee32d96affb.tar pttbbs-4ec6b30667d83b998fa9cc1e18e34ee32d96affb.tar.gz pttbbs-4ec6b30667d83b998fa9cc1e18e34ee32d96affb.tar.bz2 pttbbs-4ec6b30667d83b998fa9cc1e18e34ee32d96affb.tar.lz pttbbs-4ec6b30667d83b998fa9cc1e18e34ee32d96affb.tar.xz pttbbs-4ec6b30667d83b998fa9cc1e18e34ee32d96affb.tar.zst pttbbs-4ec6b30667d83b998fa9cc1e18e34ee32d96affb.zip |
show memory usage by hitting Ctrl-Q in DEBUG mode
git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk/pttbbs@599 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd/io.c')
-rw-r--r-- | mbbsd/io.c | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -1,4 +1,4 @@ -/* $Id: io.c,v 1.25 2002/12/24 08:20:15 in2 Exp $ */ +/* $Id: io.c,v 1.26 2003/01/15 09:41:19 in2 Exp $ */ #include "bbs.h" #if defined(linux) @@ -153,6 +153,11 @@ igetch() register int ch; while ((ch = dogetch())) { switch (ch) { +#ifdef DEBUG + case Ctrl('Q'): + vmsg("memory usage: %d KB", ((int)sbrk(0) - 0x8048000) / 1024); + continue; +#endif case Ctrl('L'): redoscr(); continue; |