summaryrefslogtreecommitdiffstats
path: root/mbbsd/mail.c
diff options
context:
space:
mode:
authorptt <ptt@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2004-04-30 04:42:54 +0800
committerptt <ptt@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2004-04-30 04:42:54 +0800
commitf96e3fe469a9cf18c385e27297d987e80f5af0a5 (patch)
treecdf1ebfc936709efd116e3eeb448e487d639877a /mbbsd/mail.c
parentb46eb1e0f400514ca8fa7a761711040fdbd7dc6a (diff)
downloadpttbbs-f96e3fe469a9cf18c385e27297d987e80f5af0a5.tar
pttbbs-f96e3fe469a9cf18c385e27297d987e80f5af0a5.tar.gz
pttbbs-f96e3fe469a9cf18c385e27297d987e80f5af0a5.tar.bz2
pttbbs-f96e3fe469a9cf18c385e27297d987e80f5af0a5.tar.lz
pttbbs-f96e3fe469a9cf18c385e27297d987e80f5af0a5.tar.xz
pttbbs-f96e3fe469a9cf18c385e27297d987e80f5af0a5.tar.zst
pttbbs-f96e3fe469a9cf18c385e27297d987e80f5af0a5.zip
1.fix some bug for reference tag
2.add static _mode to cost down select_read's time. Note: getindex is a bad!! funcation...must get ride of that some day. git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@1892 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd/mail.c')
-rw-r--r--mbbsd/mail.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/mbbsd/mail.c b/mbbsd/mail.c
index 053796a9..f4a53dfa 100644
--- a/mbbsd/mail.c
+++ b/mbbsd/mail.c
@@ -832,7 +832,7 @@ mail_del(int ent, fileheader_t * fhdr, char *direct)
if ((currmode & MODE_SELECT)) {
int index;
sethomedir(genbuf, cuser.userid);
- index = getindex(genbuf, fhdr->filename, sizeof(fileheader_t));
+ index = getindex(genbuf, fhdr->filename);
delete_record(genbuf, sizeof(fileheader_t), index);
}
return DIRCHANGED;
@@ -859,8 +859,7 @@ mail_read(int ent, fileheader_t * fhdr, char *direct)
if ((currmode & MODE_SELECT)) {
int index;
- index = getindex(currmaildir, fhdr->filename,
- sizeof(fileheader_t));
+ index = getindex(currmaildir, fhdr->filename);
substitute_record(currmaildir, fhdr, sizeof(*fhdr), index);
substitute_record(direct, fhdr, sizeof(*fhdr), ent);
} else
@@ -904,7 +903,7 @@ mail_read(int ent, fileheader_t * fhdr, char *direct)
if ((currmode & MODE_SELECT)) {
int index;
- index = getindex(currmaildir, fhdr->filename, sizeof(fileheader_t));
+ index = getindex(currmaildir, fhdr->filename);
substitute_record(currmaildir, fhdr, sizeof(*fhdr), index);
substitute_record(direct, fhdr, sizeof(*fhdr), ent);
} else
@@ -1003,7 +1002,7 @@ mail_mark(int ent, fileheader_t * fhdr, char *direct)
if ((currmode & MODE_SELECT)) {
int index;
- index = getindex(currmaildir, fhdr->filename, sizeof(fileheader_t));
+ index = getindex(currmaildir, fhdr->filename);
substitute_record(currmaildir, fhdr, sizeof(*fhdr), index);
substitute_record(direct, fhdr, sizeof(*fhdr), ent);
} else