From defbdb6544e58ade4316af4a2e003568d34aa6a1 Mon Sep 17 00:00:00 2001 From: ptt Date: Tue, 3 Jan 2006 17:36:57 +0000 Subject: 1. add "cancel bad post" feature. 2. fix bad the bug that user won't get bad post when he is online. git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@3260 63ad8ddf-47c3-0310-b6dd-a9e9d9715204 --- include/proto.h | 1 + include/pttstruct.h | 13 +++++++++---- 2 files changed, 10 insertions(+), 4 deletions(-) (limited to 'include') diff --git a/include/proto.h b/include/proto.h index a4e8dbf2..6faa25de 100644 --- a/include/proto.h +++ b/include/proto.h @@ -715,6 +715,7 @@ int u_editcalendar(void); void user_display(const userec_t *u, int real); void uinfo_query(userec_t *u, int real, int unum); int showsignature(char *fname, int *j, SigInfo *psi); +int u_cancelbadpost(); void kick_all(char *user); void violate_law(userec_t * u, int unum); void mail_violatelaw(const char* crime, const char* police, const char* reason, const char* result); diff --git a/include/pttstruct.h b/include/pttstruct.h index 78882529..362f3dd0 100644 --- a/include/pttstruct.h +++ b/include/pttstruct.h @@ -108,7 +108,8 @@ typedef struct userec_t { char myangel[IDLEN+1]; /* 我的小天使 */ unsigned short chess_elo_rating; /* 象棋等級分 */ unsigned int withme; /* 我想找人下棋,聊天.... */ - char pad[34]; + time4_t timeremovebadpost; /* 上次刪除劣文時間 */ + char pad[30]; } userec_t; /* these are flags in userec_t.uflag */ #define PAGER_FLAG 0x4 /* true if pager was OFF last session */ @@ -331,10 +332,11 @@ typedef struct msgque_t { int msgmode; } msgque_t; -#define ALERT_NEW_MAIL 1 +#define ALERT_NEW_MAIL 1 #define ISNEWMAIL(utmp) utmp->alerts & ALERT_NEW_MAIL -#define ALERT_RELOAD_PERM 2 - +#define ALERT_PWD_PERM 2 +#define ALERT_PWD_BADPOST 4 +#define ALERT_PWD (ALERT_PWD_PERM|ALERT_PWD_BADPOST) /* user data in shm */ /* use GAP to detect and avoid data overflow and overriding */ typedef struct userinfo_t { @@ -349,10 +351,13 @@ typedef struct userinfo_t { char from[27]; /* machine name the user called in from */ int from_alias; char sex; + char nonuse[4]; + /* unsigned char goodpost; unsigned char badpost; unsigned char goodsale; unsigned char badsale; + */ unsigned char angel; /* friends */ -- cgit v1.2.3