diff options
author | piaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2008-05-14 03:43:22 +0800 |
---|---|---|
committer | piaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2008-05-14 03:43:22 +0800 |
commit | 584b00dfc540b2911e865b81bf5e213905cd9b8a (patch) | |
tree | 30f2e4e36ad244423b2063fecdd67322790db287 /mbbsd | |
parent | 41d98092590000461272203026766702d624fa99 (diff) | |
download | pttbbs-584b00dfc540b2911e865b81bf5e213905cd9b8a.tar pttbbs-584b00dfc540b2911e865b81bf5e213905cd9b8a.tar.gz pttbbs-584b00dfc540b2911e865b81bf5e213905cd9b8a.tar.bz2 pttbbs-584b00dfc540b2911e865b81bf5e213905cd9b8a.tar.lz pttbbs-584b00dfc540b2911e865b81bf5e213905cd9b8a.tar.xz pttbbs-584b00dfc540b2911e865b81bf5e213905cd9b8a.tar.zst pttbbs-584b00dfc540b2911e865b81bf5e213905cd9b8a.zip |
- mail: ignore self from reject list
- record/mbbsd: drop unused code
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@4309 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd')
-rw-r--r-- | mbbsd/mail.c | 5 | ||||
-rw-r--r-- | mbbsd/mbbsd.c | 25 | ||||
-rw-r--r-- | mbbsd/record.c | 1 |
3 files changed, 6 insertions, 25 deletions
diff --git a/mbbsd/mail.c b/mbbsd/mail.c index c23298c3..978a21c0 100644 --- a/mbbsd/mail.c +++ b/mbbsd/mail.c @@ -2085,6 +2085,11 @@ doforward(const char *direct, const fileheader_t * fh, int mode) vmsg("找不到此使用者 ID。"); return 1; } + + // some stupid users set self as rejects. + if (strcasecmp(xid, cuser.userid) == 0) + break; + sethomefile(fpath, xid, FN_OVERRIDES); i = belong(fpath, cuser.userid); sethomefile(fpath, xid, FN_REJECT); diff --git a/mbbsd/mbbsd.c b/mbbsd/mbbsd.c index d3868532..3793ef96 100644 --- a/mbbsd/mbbsd.c +++ b/mbbsd/mbbsd.c @@ -1166,7 +1166,7 @@ user_login(void) inet_pton(AF_INET, strrchr(frombuf, ':') + 1, &xsin.sin_addr); else inet_pton(AF_INET, frombuf, &xsin.sin_addr); - getremotename(&xsin, fromhost, remoteusername); /* RFC931 */ + getremotename(&xsin, fromhost, remoteusername); } /* 初始化 uinfo、flag、mode */ @@ -1402,29 +1402,6 @@ start_client(void) main_menu(); } -/* 取得 remote user name 以判定身份 */ -/* - * rfc931() speaks a common subset of the RFC 931, AUTH, TAP, IDENT and RFC - * 1413 protocols. It queries an RFC 931 etc. compatible daemon on a remote - * host to look up the owner of a connection. The information should not be - * used for authentication purposes. This routine intercepts alarm signals. - * - * Author: Wietse Venema, Eindhoven University of Technology, The Netherlands. - */ - -#define RFC931_TIMEOUT 10 -#define RFC931_PORT 113 /* Semi-well-known port */ -#define ANY_PORT 0 /* Any old port will do */ - -#if 0 -/* timeout - handle timeouts */ -static void -timeout(int sig) -{ - longjmp(byebye, sig); -} -#endif - static void getremotename(const struct sockaddr_in * from, char *rhost, char *rname) { diff --git a/mbbsd/record.c b/mbbsd/record.c index 8618be63..e0b22adc 100644 --- a/mbbsd/record.c +++ b/mbbsd/record.c @@ -2,7 +2,6 @@ #include "bbs.h" -#undef HAVE_MMAP #define BUFSIZE 512 #define safewrite write |