diff src/imap/client.c @ 674:b7aefd0d7611 HEAD

Locking changes triggered a bit larger cleanup :) If we have to wait for a lock longer, the client is now notified about it every 30 seconds. Also if mailbox opening fails because of lock timeout, we won't overwrite the index anymore. Finally user gets a clear error message about lock timeout instead of "internal error".
author Timo Sirainen <tss@iki.fi>
date Mon, 25 Nov 2002 21:02:49 +0200
parents 3b53dd1280c6
children 3f817df5eba4
line wrap: on
line diff
--- a/src/imap/client.c	Mon Nov 25 17:00:53 2002 +0200
+++ b/src/imap/client.c	Mon Nov 25 21:02:49 2002 +0200
@@ -25,6 +25,8 @@
 /* Disconnect client after idling this many seconds */
 #define CLIENT_IDLE_TIMEOUT (60*30)
 
+extern MailStorageCallbacks mail_storage_callbacks;
+
 static Client *my_client; /* we don't need more than one currently */
 static Timeout to_idle;
 
@@ -76,6 +78,7 @@
         client->last_input = ioloop_time;
 
 	client->storage = storage;
+	storage->set_callbacks(storage, &mail_storage_callbacks, client);
 
 	i_assert(my_client == NULL);
 	my_client = client;