# HG changeset patch # User Stephan Bosch # Date 1488411733 -3600 # Node ID e54c9d8d99368feada81cde1d3b8b115083aea2d # Parent 2cfa5218955e8aeb7bcd31dac37e44949206aaa6 lib-smtp: lmtp-client: Fixed bug in timeout handling. The timeout was erroneously stopped when lmtp_client_send() was invoked before a connection was established. Once the connection finally got established, the timeout was removed. This would cause the client to wait indefinitely. diff -r 2cfa5218955e -r e54c9d8d9936 src/lib-smtp/lmtp-client.c --- a/src/lib-smtp/lmtp-client.c Thu Mar 02 00:03:50 2017 +0100 +++ b/src/lib-smtp/lmtp-client.c Thu Mar 02 00:42:13 2017 +0100 @@ -634,7 +634,7 @@ " (connect)"); return; } - if (client->to != NULL) + if (client->data_input == NULL && client->to != NULL) timeout_remove(&client->to); io_remove(&client->io); client->io = io_add(client->fd, IO_READ, lmtp_client_input, client);