From 73df3b82f606dae8f24a26dbb6a9285f693c457f Mon Sep 17 00:00:00 2001 From: piaip Date: Tue, 22 Apr 2008 12:14:47 +0000 Subject: - (mail) more hints and check on auto-forward settings - (board) hints on Ctrl-S to search for local boards git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@4231 63ad8ddf-47c3-0310-b6dd-a9e9d9715204 --- mbbsd/board.c | 6 +++++- mbbsd/mail.c | 11 +++++++++++ 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/mbbsd/board.c b/mbbsd/board.c index a38235da..e531a0d6 100644 --- a/mbbsd/board.c +++ b/mbbsd/board.c @@ -1618,7 +1618,11 @@ choose_board(int newflag) char bname[IDLEN*2]; move(0, 0); clrtoeol(); - CompleteBoardAndGroup(MSG_SELECT_BOARD, bname); + CompleteBoardAndGroup(ANSI_REVERSE + "【 搜尋全站看板 】" ANSI_RESET + " (若要限定搜尋範圍為目前列表請改用 Ctrl-S)\n" + "請輸入看板名稱(按空白鍵自動搜尋): ", + bname); // force refresh head = -1; if (!*bname) diff --git a/mbbsd/mail.c b/mbbsd/mail.c index 3dcf82be..c8bef300 100644 --- a/mbbsd/mail.c +++ b/mbbsd/mail.c @@ -44,6 +44,17 @@ setforward(void) getdata_buf(b_lines - 1, 0, "請輸入自動轉寄的Email: ", ip, sizeof(ip), DOECHO); + if (strchr(ip, '@') == NULL) + { + // check if this is a valid local user + if (searchuser(ip, ip) <= 0) + { + unlink(buf); + vmsg("轉寄對象不存在,已取消自動轉寄。"); + return 0; + } + } + /* anti idiots */ if (strncasecmp(ip, cuser.userid, oidlen) == 0) { -- cgit v1.2.3