Mercurial > dovecot > core-2.2
changeset 151:e0f995ee5969 HEAD
s/updateid/sync_id/ like it was with modify log.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Wed, 04 Sep 2002 18:24:05 +0300 |
parents | cb05d392ad24 |
children | 7e1f18c5d708 |
files | src/lib-index/mail-hash.c src/lib-index/mail-hash.h src/lib-index/mail-index-compress.c src/lib-index/mail-index.c src/lib-index/mail-index.h |
diffstat | 5 files changed, 14 insertions(+), 14 deletions(-) [+] |
line wrap: on
line diff
--- a/src/lib-index/mail-hash.c Wed Sep 04 18:19:42 2002 +0300 +++ b/src/lib-index/mail-hash.c Wed Sep 04 18:24:05 2002 +0300 @@ -38,7 +38,7 @@ struct _MailHash { MailIndex *index; - unsigned int updateid; + unsigned int sync_id; unsigned int size; int fd; @@ -85,7 +85,7 @@ } hash->header = hash->mmap_base; - hash->updateid = hash->header->updateid; + hash->sync_id = hash->header->sync_id; hash->size = (hash->mmap_length - sizeof(MailHashHeader)) / sizeof(MailHashRecord); @@ -108,7 +108,7 @@ if (!hash->dirty_mmap) { /* see if someone else modified it */ - if (hash->header->updateid == hash->updateid) + if (hash->header->sync_id == hash->sync_id) return TRUE; } @@ -290,7 +290,7 @@ /* setup header */ hdr = mmap_base; hdr->indexid = index->indexid; - hdr->updateid = ioloop_time; + hdr->sync_id = ioloop_time; hdr->used_records = count; return munmap(mmap_base, mmap_length) == 0;
--- a/src/lib-index/mail-hash.h Wed Sep 04 18:19:42 2002 +0300 +++ b/src/lib-index/mail-hash.h Wed Sep 04 18:24:05 2002 +0300 @@ -6,7 +6,7 @@ struct _MailHashHeader { unsigned int indexid; - unsigned int updateid; + unsigned int sync_id; unsigned int used_records; unsigned int alignment;
--- a/src/lib-index/mail-index-compress.c Wed Sep 04 18:19:42 2002 +0300 +++ b/src/lib-index/mail-index-compress.c Wed Sep 04 18:24:05 2002 +0300 @@ -61,7 +61,7 @@ index->header->first_hole_position = 0; index->header->first_hole_records = 0; - index->header->updateid++; + index->header->sync_id++; index->dirty_mmap = TRUE; /* make sure the whole file is synced before removing rebuild-flag */
--- a/src/lib-index/mail-index.c Wed Sep 04 18:19:42 2002 +0300 +++ b/src/lib-index/mail-index.c Wed Sep 04 18:24:05 2002 +0300 @@ -29,7 +29,7 @@ index->header = (MailIndexHeader *) index->mmap_base; /* make sure file size hasn't changed */ - if (index->header->updateid == index->updateid) + if (index->header->sync_id == index->sync_id) return TRUE; } @@ -65,7 +65,7 @@ index->last_lookup = NULL; index->header = (MailIndexHeader *) index->mmap_base; - index->updateid = index->header->updateid; + index->sync_id = index->header->sync_id; index->dirty_mmap = FALSE; return TRUE; } @@ -1233,7 +1233,7 @@ index->header->first_hole_position = 0; index->header->first_hole_records = 0; - index->header->updateid++; + index->header->sync_id++; index->dirty_mmap = TRUE; if (index->header->messages_count == 0) { @@ -1391,8 +1391,8 @@ mail_hash_update(index->hash, (*rec)->uid, (uoff_t)pos); /* file size changed, let others know about it too by changing - updateid in header. */ - index->header->updateid++; + sync_id in header. */ + index->header->sync_id++; index->dirty_mmap = TRUE; if (!mmap_update(index))
--- a/src/lib-index/mail-index.h Wed Sep 04 18:19:42 2002 +0300 +++ b/src/lib-index/mail-index.h Wed Sep 04 18:24:05 2002 +0300 @@ -86,8 +86,8 @@ 5 = MEM_ALIGN_SIZE */ unsigned int indexid; - unsigned int updateid; /* re-mmap() when changed, required only - if file size is changed */ + unsigned int sync_id; /* re-mmap() when changed, required only + if file size is changed */ unsigned int flags; unsigned int cache_fields; @@ -289,7 +289,7 @@ char *dir; /* directory where to place the index files */ char *filepath; /* index file path */ unsigned int indexid; - unsigned int updateid; + unsigned int sync_id; char *mbox_path; /* mbox-specific path to the actual mbox file */ uoff_t mbox_size; /* last synced size of mbox file */