projects
/
citadel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
5226db6
)
* Made some annotations regarding bug 368 in the code.
author
Art Cancro
<ajc@citadel.org>
Mon, 2 Nov 2009 03:54:39 +0000
(
03:54
+0000)
committer
Art Cancro
<ajc@citadel.org>
Mon, 2 Nov 2009 03:54:39 +0000
(
03:54
+0000)
citadel/modules/imap/serv_imap.c
patch
|
blob
|
history
diff --git
a/citadel/modules/imap/serv_imap.c
b/citadel/modules/imap/serv_imap.c
index 3efe4a4e494f088e0147e3dbe997dcb1a79af6d0..9cd1452f690abe65dab011021eef0c20bb6152de 100644
(file)
--- a/
citadel/modules/imap/serv_imap.c
+++ b/
citadel/modules/imap/serv_imap.c
@@
-221,10
+221,8
@@
void imap_add_single_msgid(long msgnum, void *userdata)
++IMAP->num_msgs;
if (IMAP->num_msgs > IMAP->num_alloc) {
IMAP->num_alloc += REALLOC_INCREMENT;
++IMAP->num_msgs;
if (IMAP->num_msgs > IMAP->num_alloc) {
IMAP->num_alloc += REALLOC_INCREMENT;
- IMAP->msgids = realloc(IMAP->msgids,
- (IMAP->num_alloc * sizeof(long)) );
- IMAP->flags = realloc(IMAP->flags,
- (IMAP->num_alloc * sizeof(long)) );
+ IMAP->msgids = realloc(IMAP->msgids, (IMAP->num_alloc * sizeof(long)) );
+ IMAP->flags = realloc(IMAP->flags, (IMAP->num_alloc * sizeof(long)) );
}
IMAP->msgids[IMAP->num_msgs - 1] = msgnum;
IMAP->flags[IMAP->num_msgs - 1] = 0;
}
IMAP->msgids[IMAP->num_msgs - 1] = msgnum;
IMAP->flags[IMAP->num_msgs - 1] = 0;
@@
-282,8
+280,7
@@
void imap_rescan_msgids(void)
int num_recent = 0;
if (IMAP->selected == 0) {
int num_recent = 0;
if (IMAP->selected == 0) {
- CtdlLogPrintf(CTDL_ERR,
- "imap_load_msgids() can't run; no room selected\n");
+ CtdlLogPrintf(CTDL_ERR, "imap_load_msgids() can't run; no room selected\n");
return;
}
return;
}
@@
-367,6
+364,8
@@
void imap_rescan_msgids(void)
/*
* Now peruse the room for *new* messages only.
/*
* Now peruse the room for *new* messages only.
+ * This logic is probably the cause of Bug # 368
+ * [ http://bugzilla.citadel.org/show_bug.cgi?id=368 ]
*/
if (num_msgs > 0) {
for (j = 0; j < num_msgs; ++j) {
*/
if (num_msgs > 0) {
for (j = 0; j < num_msgs; ++j) {