From: Martti Rannanjärvi Date: Fri, 3 Jun 2022 01:05:26 +0000 (+0300) Subject: global: Use ioloop_time32 more when ioloop_time is used as uint32_t X-Git-Tag: 2.4.0~3996 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=465486f24e5ce675cba48a5289fded847385d359;p=thirdparty%2Fdovecot%2Fcore.git global: Use ioloop_time32 more when ioloop_time is used as uint32_t These were missing from 138bee2f638a53415a1729b6a9476eb342b40831. --- diff --git a/src/director/director-connection.c b/src/director/director-connection.c index f2b38ab2e0..0b94ba9d3b 100644 --- a/src/director/director-connection.c +++ b/src/director/director-connection.c @@ -1747,7 +1747,7 @@ static bool director_connection_sync(struct director_connection *conn, causes unnecessary error logging and hosts-resending. */ if ((host == NULL || !host->self) && dir->last_sync_sent_ring_change_counter != dir->ring_change_counter && - (time_t)dir->self_host->last_sync_timestamp != ioloop_time) + dir->self_host->last_sync_timestamp != ioloop_time32) (void)director_resend_sync(dir); return TRUE; } diff --git a/src/director/director.c b/src/director/director.c index 17d8e64822..3e2e58bdd4 100644 --- a/src/director/director.c +++ b/src/director/director.c @@ -422,7 +422,7 @@ bool director_resend_sync(struct director *dir) } } else if (dir->left != NULL) { /* send a new SYNC in case the previous one got dropped */ - dir->self_host->last_sync_timestamp = ioloop_time; + dir->self_host->last_sync_timestamp = ioloop_time32; director_sync_send(dir, dir->self_host, dir->sync_seq, DIRECTOR_VERSION_MINOR, ioloop_time32, mail_hosts_hash(dir->mail_hosts)); @@ -1172,7 +1172,7 @@ void director_move_user(struct director *dir, struct director_host *src, user->host->user_count--; user->host = host; user->host->user_count++; - user->timestamp = ioloop_time; + user->timestamp = ioloop_time32; e_debug(dir->event, "User %u move started: host %s -> %s", username_hash, old_host->ip_str, host->ip_str); diff --git a/src/lib-index/mail-cache-purge.c b/src/lib-index/mail-cache-purge.c index bc86bf1839..477f80d2a3 100644 --- a/src/lib-index/mail-cache-purge.c +++ b/src/lib-index/mail-cache-purge.c @@ -108,7 +108,7 @@ static uint32_t get_next_file_seq(struct mail_cache *cache) view = mail_index_view_open(cache->index); ext = mail_index_view_get_ext(view, cache->ext_id); - file_seq = ext != NULL ? ext->reset_id + 1 : (uint32_t)ioloop_time; + file_seq = ext != NULL ? ext->reset_id + 1 : ioloop_time32; if (cache->hdr != NULL && file_seq <= cache->hdr->file_seq) file_seq = cache->hdr->file_seq + 1; diff --git a/src/lib-storage/index/index-storage.c b/src/lib-storage/index/index-storage.c index f062eec75f..31ce6bb730 100644 --- a/src/lib-storage/index/index-storage.c +++ b/src/lib-storage/index/index-storage.c @@ -923,7 +923,7 @@ int index_storage_mailbox_rename(struct mailbox *src, struct mailbox *dest) struct mail_index_transaction *t = mail_index_transaction_begin(dest->view, 0); - uint32_t stamp = ioloop_time; + uint32_t stamp = ioloop_time32; mail_index_update_header_ext(t, dest->box_last_rename_stamp_ext_id, 0, &stamp, sizeof(stamp));