[dovecot-cvs] dovecot/src/lib-index mail-cache-compress.c, 1.10,
1.11
cras at dovecot.org
cras at dovecot.org
Fri Jul 9 00:27:24 EEST 2004
- Previous message: [dovecot-cvs] dovecot/src/lib-storage/index index-fetch.c, 1.54,
1.55 index-mail-headers.c, 1.24, 1.25 index-mail.c, 1.40,
1.41 index-mail.h, 1.15, 1.16 index-search.c, 1.90,
1.91 index-storage.c, 1.55, 1.56
- Next message: [dovecot-cvs] dovecot/src/lib-storage/index index-mail-headers.c,
1.25, 1.26 index-mail.c, 1.41, 1.42 index-mail.h, 1.16,
1.17 index-transaction.c, 1.7, 1.8
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /home/cvs/dovecot/src/lib-index
In directory talvi:/tmp/cvs-serv2465/lib-index
Modified Files:
mail-cache-compress.c
Log Message:
Fixed compression.
Index: mail-cache-compress.c
===================================================================
RCS file: /home/cvs/dovecot/src/lib-index/mail-cache-compress.c,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -d -r1.10 -r1.11
--- mail-cache-compress.c 8 Jul 2004 20:26:15 -0000 1.10
+++ mail-cache-compress.c 8 Jul 2004 21:27:22 -0000 1.11
@@ -184,13 +184,16 @@
}
}
- if (buffer_get_used_size(ctx.buffer) == sizeof(cache_rec))
+ cache_rec.size = buffer_get_used_size(ctx.buffer);
+ if (cache_rec.size == sizeof(cache_rec))
continue;
mail_index_update_cache(t, seq, hdr.file_seq,
output->offset, &old_offset);
+
+ buffer_write(ctx.buffer, 0, &cache_rec, sizeof(cache_rec));
o_stream_send(output, buffer_get_data(ctx.buffer, NULL),
- buffer_get_used_size(ctx.buffer));
+ cache_rec.size);
}
hdr.used_file_size = output->offset;
buffer_free(ctx.buffer);
@@ -209,7 +212,7 @@
return -1;
}
- if (output->offset < MAIL_CACHE_INITIAL_SIZE) {
+ if (hdr.used_file_size < MAIL_CACHE_INITIAL_SIZE) {
/* grow the file some more. doesn't matter if it fails */
(void)file_set_size(fd, MAIL_CACHE_INITIAL_SIZE);
}
- Previous message: [dovecot-cvs] dovecot/src/lib-storage/index index-fetch.c, 1.54,
1.55 index-mail-headers.c, 1.24, 1.25 index-mail.c, 1.40,
1.41 index-mail.h, 1.15, 1.16 index-search.c, 1.90,
1.91 index-storage.c, 1.55, 1.56
- Next message: [dovecot-cvs] dovecot/src/lib-storage/index index-mail-headers.c,
1.25, 1.26 index-mail.c, 1.41, 1.42 index-mail.h, 1.16,
1.17 index-transaction.c, 1.7, 1.8
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the dovecot-cvs
mailing list