]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
dsync: Avoid hanging when saving messages.
authorTimo Sirainen <tss@iki.fi>
Mon, 7 Mar 2011 17:35:09 +0000 (19:35 +0200)
committerTimo Sirainen <tss@iki.fi>
Mon, 7 Mar 2011 17:35:09 +0000 (19:35 +0200)
src/dsync/dsync-proxy-client.c

index cc54a1c0fae4876ba366b49f10a36b9bce7ebb70..da31c1642de3db085b3da42cb8ac7676dedf29b2 100644 (file)
@@ -364,8 +364,10 @@ proxy_client_worker_output_real(struct proxy_client_dsync_worker *worker)
                /* proxy_client_worker_msg_save() hasn't finished yet. */
                o_stream_cork(worker->output);
                proxy_client_send_stream(worker);
-               if (worker->save_input != NULL)
-                       return 1;
+               if (worker->save_input != NULL) {
+                       /* still unfinished, make sure we get called again */
+                       return 0;
+               }
        }
 
        if (worker->worker.output_callback != NULL)