Mercurial > dovecot > original-hg > dovecot-1.2
changeset 3223:f3c1a9a32a8e HEAD
Array code changes broke setting old_data_r in mail_index_update_ext(). This
kept breaking cache file.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Thu, 24 Mar 2005 23:00:10 +0200 |
parents | e38e04c7c67c |
children | f6e0d1826645 |
files | src/lib-index/mail-index-transaction.c |
diffstat | 1 files changed, 4 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/lib-index/mail-index-transaction.c Thu Mar 24 22:28:28 2005 +0200 +++ b/src/lib-index/mail-index-transaction.c Thu Mar 24 23:00:10 2005 +0200 @@ -685,8 +685,10 @@ if (mail_index_seq_array_lookup(array, seq, &idx)) { /* already there, update */ p = array_modifyable_idx(array, idx); - if (old_record != NULL) - memcpy(old_record, p, record_size); + if (old_record != NULL) { + memcpy(old_record, PTR_OFFSET(p, sizeof(seq)), + record_size); + } memcpy(PTR_OFFSET(p, sizeof(seq)), record, record_size); return TRUE; } else {