[dovecot-cvs] dovecot/src/lib-storage/index index-mail-headers.c, 1.29, 1.30 index-mail.c, 1.45, 1.46

cras at dovecot.org cras at dovecot.org
Tue Jul 20 19:50:58 EEST 2004


Update of /home/cvs/dovecot/src/lib-storage/index
In directory talvi:/tmp/cvs-serv22286/lib-storage/index

Modified Files:
	index-mail-headers.c index-mail.c 
Log Message:
Cache fixes. Decisions are saved again.



Index: index-mail-headers.c
===================================================================
RCS file: /home/cvs/dovecot/src/lib-storage/index/index-mail-headers.c,v
retrieving revision 1.29
retrieving revision 1.30
diff -u -d -r1.29 -r1.30
--- index-mail-headers.c	18 Jul 2004 17:34:32 -0000	1.29
+++ index-mail-headers.c	20 Jul 2004 16:50:56 -0000	1.30
@@ -91,6 +91,7 @@
 					      lines[i].end_pos -
 					      lines[i].start_pos);
 			}
+			i--;
 		} else {
 			buffer_append(buf, header + lines[i].start_pos,
 				      lines[j-1].end_pos - lines[i].start_pos);
@@ -359,7 +360,7 @@
 {
 	struct mail_cache_field header_field = {
 		NULL, 0, MAIL_CACHE_FIELD_HEADER, 0,
-		MAIL_CACHE_DECISION_TEMP, 0, 0
+		MAIL_CACHE_DECISION_TEMP
 	};
 	const char *cache_field_name;
 	unsigned int field_idx;
@@ -491,7 +492,7 @@
 	struct index_mailbox *ibox = (struct index_mailbox *)box;
 	struct mail_cache_field *fields, header_field = {
 		NULL, 0, MAIL_CACHE_FIELD_HEADER, 0,
-		MAIL_CACHE_DECISION_TEMP, 0, 0
+		MAIL_CACHE_DECISION_TEMP
 	};
 	struct index_header_lookup_ctx *ctx;
 	const char *const *name;

Index: index-mail.c
===================================================================
RCS file: /home/cvs/dovecot/src/lib-storage/index/index-mail.c,v
retrieving revision 1.45
retrieving revision 1.46
diff -u -d -r1.45 -r1.46
--- index-mail.c	18 Jul 2004 17:34:32 -0000	1.45
+++ index-mail.c	20 Jul 2004 16:50:56 -0000	1.46
@@ -14,19 +14,18 @@
 #include "index-mail.h"
 
 struct mail_cache_field cache_fields[MAIL_CACHE_FIELD_COUNT] = {
-	{ "index.flags", 0, MAIL_CACHE_FIELD_BITMASK,
-	  sizeof(uint32_t), 0, 0, 0 },
+	{ "index.flags", 0, MAIL_CACHE_FIELD_BITMASK, sizeof(uint32_t), 0 },
 	{ "date.sent", 0, MAIL_CACHE_FIELD_FIXED_SIZE,
-	  sizeof(struct mail_sent_date), 0, 0, 0 },
+	  sizeof(struct mail_sent_date), 0 },
 	{ "date.received", 0, MAIL_CACHE_FIELD_FIXED_SIZE,
-	  sizeof(time_t), 0, 0, 0 },
+	  sizeof(time_t), 0 },
 	{ "size.virtual", 0, MAIL_CACHE_FIELD_FIXED_SIZE,
-	  sizeof(uoff_t), 0, 0, 0 },
-	{ "imap.body", 0, MAIL_CACHE_FIELD_STRING, 0, 0, 0, 0 },
-	{ "imap.bodystructure", 0, MAIL_CACHE_FIELD_STRING, 0, 0, 0, 0 },
-	{ "imap.envelope", 0, MAIL_CACHE_FIELD_STRING, 0, 0, 0, 0 },
-	{ "mime.parts", 0, MAIL_CACHE_FIELD_VARIABLE_SIZE, 0, 0, 0, 0 },
-	{ "mail.uid", 0, MAIL_CACHE_FIELD_STRING, 0, 0, 0, 0 }
+	  sizeof(uoff_t), 0 },
+	{ "imap.body", 0, MAIL_CACHE_FIELD_STRING, 0, 0 },
+	{ "imap.bodystructure", 0, MAIL_CACHE_FIELD_STRING, 0, 0 },
+	{ "imap.envelope", 0, MAIL_CACHE_FIELD_STRING, 0, 0 },
+	{ "mime.parts", 0, MAIL_CACHE_FIELD_VARIABLE_SIZE, 0, 0 },
+	{ "mail.uid", 0, MAIL_CACHE_FIELD_STRING, 0, 0 }
 };
 
 static void index_mail_parse_body(struct index_mail *mail, int need_parts);



More information about the dovecot-cvs mailing list