[dovecot-cvs] dovecot/src/lib-storage/index/dbox dbox-keywords.c, 1.4, 1.5 dbox-save.c, 1.18, 1.19 dbox-sync-expunge.c, 1.19, 1.20 dbox-sync-full.c, 1.8, 1.9 dbox-sync.c, 1.21, 1.22 dbox-uidlist.c, 1.38, 1.39

cras at dovecot.org cras at dovecot.org
Sun Sep 10 15:33:24 EEST 2006


Update of /var/lib/cvs/dovecot/src/lib-storage/index/dbox
In directory talvi:/tmp/cvs-serv1034/lib-storage/index/dbox

Modified Files:
	dbox-keywords.c dbox-save.c dbox-sync-expunge.c 
	dbox-sync-full.c dbox-sync.c dbox-uidlist.c 
Log Message:
Removed type parameter from ARRAY_CREATE since it's not needed anymore.



Index: dbox-keywords.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/dbox/dbox-keywords.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- dbox-keywords.c	28 Jun 2006 13:10:50 -0000	1.4
+++ dbox-keywords.c	10 Sep 2006 12:33:20 -0000	1.5
@@ -33,9 +33,9 @@
 		array_clear(&file->file_idx_keywords);
 	} else {
 		ARRAY_CREATE(&file->idx_file_keywords, default_pool,
-			     struct keyword_map, file->keyword_count);
+			     file->keyword_count);
 		ARRAY_CREATE(&file->file_idx_keywords, default_pool,
-			     unsigned int, file->keyword_count);
+			     file->keyword_count);
 	}
 
 	/* currently we assume that all extra space at the end of header

Index: dbox-save.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/dbox/dbox-save.c,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -d -r1.18 -r1.19
--- dbox-save.c	23 Jul 2006 22:40:54 -0000	1.18
+++ dbox-save.c	10 Sep 2006 12:33:20 -0000	1.19
@@ -51,8 +51,7 @@
 	/* Get a list of all new keywords. Using seq_range is the easiest
 	   way to do this and should be pretty fast too. */
 	t_push();
-	ARRAY_CREATE(&new_keywords, pool_datastack_create(),
-		     struct seq_range, 16);
+	ARRAY_CREATE(&new_keywords, pool_datastack_create(), 16);
 	for (i = 0; i < keywords->count; i++) {
 		/* check if it's already in the file */
 		if (dbox_file_lookup_keyword(ctx->mbox, ctx->file,

Index: dbox-sync-expunge.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/dbox/dbox-sync-expunge.c,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -d -r1.19 -r1.20
--- dbox-sync-expunge.c	23 Jul 2006 19:08:58 -0000	1.19
+++ dbox-sync-expunge.c	10 Sep 2006 12:33:20 -0000	1.20
@@ -149,7 +149,7 @@
 
 	memset(&dest_entry, 0, sizeof(dest_entry));
 	ARRAY_CREATE(&dest_entry.uid_list, pool_datastack_create(),
-		     struct seq_range, array_count(&orig_entry->uid_list));
+		     array_count(&orig_entry->uid_list));
 	dest_entry.file_seq = file_seq;
 
 	/* write file header */

Index: dbox-sync-full.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/dbox/dbox-sync-full.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- dbox-sync-full.c	28 Jun 2006 13:10:50 -0000	1.8
+++ dbox-sync-full.c	10 Sep 2006 12:33:20 -0000	1.9
@@ -89,7 +89,7 @@
 
 	t_push();
 	ARRAY_CREATE(&keywords_arr, pool_datastack_create(),
-		     unsigned int, mbox->file->keyword_count);
+		     mbox->file->keyword_count);
 	if (dbox_mail_get_keywords(mbox, mbox->file, &keywords_arr) < 0) {
 		t_pop();
 		return -1;
@@ -130,8 +130,7 @@
 
 	memset(&entry, 0, sizeof(entry));
 	entry.file_seq = file_seq;
-	ARRAY_CREATE(&entry.uid_list, pool_datastack_create(),
-		     struct seq_range, 64);
+	ARRAY_CREATE(&entry.uid_list, pool_datastack_create(), 64);
 
 	if (mbox->file->seeked_mail_header.expunged != '0') {
 		/* first mail expunged */
@@ -215,7 +214,7 @@
 	ctx->mail_index_next_uid = hdr->next_uid;
 
 	dbox_uidlist_sync_from_scratch(ctx->uidlist_sync_ctx);
-	ARRAY_CREATE(&ctx->exists, default_pool, struct seq_range, 128);
+	ARRAY_CREATE(&ctx->exists, default_pool, 128);
 
 	while ((dp = readdir(dirp)) != NULL) {
 		if (strncmp(dp->d_name, DBOX_MAIL_FILE_PREFIX,

Index: dbox-sync.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/dbox/dbox-sync.c,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -d -r1.21 -r1.22
--- dbox-sync.c	23 Jul 2006 16:50:53 -0000	1.21
+++ dbox-sync.c	10 Sep 2006 12:33:20 -0000	1.22
@@ -64,8 +64,7 @@
 	if (entry == NULL) {
 		entry = p_new(ctx->pool, struct dbox_sync_file_entry, 1);
 		entry->file_seq = file_seq;
-		ARRAY_CREATE(&entry->sync_recs, ctx->pool,
-			     struct dbox_sync_rec, 3);
+		ARRAY_CREATE(&entry->sync_recs, ctx->pool, 3);
 		hash_insert(ctx->syncs, POINTER_CAST(file_seq), entry);
 	}
 
@@ -328,7 +327,7 @@
 	/* Get a list of all new keywords. Using seq_range is the easiest
 	   way to do this and should be pretty fast too. */
 	t_push();
-	ARRAY_CREATE(&keywords, pool_datastack_create(), struct seq_range, 16);
+	ARRAY_CREATE(&keywords, pool_datastack_create(), 16);
 	sync_recs = array_get(&entry->sync_recs, &count);
 	for (; i < count; i++) {
 		if (sync_recs[i].type != MAIL_INDEX_SYNC_TYPE_KEYWORD_ADD)
@@ -423,7 +422,7 @@
 	/* read all changes and sort them to file_seq order */
 	ctx->pool = pool_alloconly_create("dbox sync pool", 10240);
 	ctx->syncs = hash_create(default_pool, ctx->pool, 0, NULL, NULL);
-	ARRAY_CREATE(&ctx->added_file_seqs, default_pool, uint32_t, 64);
+	ARRAY_CREATE(&ctx->added_file_seqs, default_pool, 64);
 	for (;;) {
 		ret = mail_index_sync_next(ctx->index_sync_ctx, &sync_rec);
 		if (ret <= 0) {

Index: dbox-uidlist.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/dbox/dbox-uidlist.c,v
retrieving revision 1.38
retrieving revision 1.39
diff -u -d -r1.38 -r1.39
--- dbox-uidlist.c	23 Jul 2006 22:42:18 -0000	1.38
+++ dbox-uidlist.c	10 Sep 2006 12:33:20 -0000	1.39
@@ -122,8 +122,7 @@
 	uidlist->path =
 		i_strconcat(mbox->path, "/"DBOX_MAILDIR_NAME"/"
 			    DBOX_UIDLIST_FILENAME, NULL);
-	ARRAY_CREATE(&uidlist->entries, default_pool,
-		     struct dbox_uidlist_entry *, 64);
+	ARRAY_CREATE(&uidlist->entries, default_pool, 64);
 	return uidlist;
 }
 
@@ -243,8 +242,7 @@
 	/* <uid list> <file seq> [<last write timestamp> <file size>] */
 	t_push();
 	entry = t_new(struct dbox_uidlist_entry, 1);
-	ARRAY_CREATE(&entry->uid_list, uidlist->entry_pool,
-		     struct seq_range, 8);
+	ARRAY_CREATE(&entry->uid_list, uidlist->entry_pool, 8);
 
 	/* get uid list */
 	range.seq1 = range.seq2 = 0;
@@ -554,7 +552,7 @@
 	ctx->uidlist = uidlist;
 	ctx->min_usable_timestamp =
 		get_min_timestamp(uidlist->mbox->rotate_days);
-	ARRAY_CREATE(&ctx->files, pool, struct dbox_save_file *, 16);
+	ARRAY_CREATE(&ctx->files, pool, 16);
 	return ctx;
 }
 
@@ -1170,7 +1168,7 @@
         save_file->dotlock = dotlock;
 	save_file->dev = st.st_dev;
 	save_file->ino = st.st_ino;
-	ARRAY_CREATE(&save_file->seqs, ctx->pool, unsigned int, 8);
+	ARRAY_CREATE(&save_file->seqs, ctx->pool, 8);
 
 	array_append(&ctx->files, &save_file, 1);
         *file_r = file;
@@ -1333,7 +1331,7 @@
 	*new_entry = *entry;
 
 	ARRAY_CREATE(&new_entry->uid_list, ctx->uidlist->entry_pool,
-		     struct seq_range, array_count(&entry->uid_list) + 1);
+		     array_count(&entry->uid_list) + 1);
 	array_append_array(&new_entry->uid_list, &entry->uid_list);
 
 	if (new_entry->file_seq > ctx->uidlist->last_file_seq)



More information about the dovecot-cvs mailing list