summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorin2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2002-05-03 01:24:35 +0800
committerin2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2002-05-03 01:24:35 +0800
commit13048f46c45a3595cfe951e6ade31ae030712495 (patch)
treee181824e2824bb9b92e2f571032a8c9114766c2d
parent92cbeda4973bec116ba5f74d524e40a13313f42f (diff)
downloadpttbbs-13048f46c45a3595cfe951e6ade31ae030712495.tar
pttbbs-13048f46c45a3595cfe951e6ade31ae030712495.tar.gz
pttbbs-13048f46c45a3595cfe951e6ade31ae030712495.tar.bz2
pttbbs-13048f46c45a3595cfe951e6ade31ae030712495.tar.lz
pttbbs-13048f46c45a3595cfe951e6ade31ae030712495.tar.xz
pttbbs-13048f46c45a3595cfe951e6ade31ae030712495.tar.zst
pttbbs-13048f46c45a3595cfe951e6ade31ae030712495.zip
show current pid if DEBUG
git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk/pttbbs@143 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r--mbbsd/menu.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/mbbsd/menu.c b/mbbsd/menu.c
index 19378b15..a765adae 100644
--- a/mbbsd/menu.c
+++ b/mbbsd/menu.c
@@ -1,9 +1,10 @@
-/* $Id: menu.c,v 1.3 2002/03/17 09:18:23 in2 Exp $ */
+/* $Id: menu.c,v 1.4 2002/05/02 17:24:35 in2 Exp $ */
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
#include <sys/types.h>
#include <string.h>
+#include <unistd.h>
#include "config.h"
#include "pttstruct.h"
#include "common.h"
@@ -55,6 +56,14 @@ void showtitle(char *title, char *mid) {
spc = strlen(mid);
if(title[0] == 0)
title++;
+#ifdef DEBUG
+ else{
+ sprintf(numreg, "\033[41;5m current pid: %6d " TITLE_COLOR,
+ getpid());
+ mid = numreg;
+ spc = 22;
+ }
+#else
else if(currutmp->mailalert) {
mid = "\033[41;5m ¶l®t¨Ó«ö¹aÅo " TITLE_COLOR;
spc = 22;
@@ -65,6 +74,7 @@ void showtitle(char *title, char *mid) {
mid = numreg;
spc = 22;
}
+#endif
spc = 66 - strlen(title) - spc - strlen(currboard);
if(spc < 0)
spc = 0;