changeset 5196:f1b735b905f3 HEAD

assert-crashfix
author Timo Sirainen <tss@iki.fi>
date Thu, 22 Feb 2007 23:49:34 +0200
parents 840d177c468f
children e77e4457d95c
files src/imap/client.c
diffstat 1 files changed, 2 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/imap/client.c	Thu Feb 22 19:32:08 2007 +0200
+++ b/src/imap/client.c	Thu Feb 22 23:49:34 2007 +0200
@@ -399,9 +399,8 @@
 
 static void client_add_missing_io(struct client *client)
 {
-	if (client->io == NULL) {
-		i_assert(i_stream_get_fd(client->input) >= 0);
-		client->io = io_add(i_stream_get_fd(client->input),
+	if (client->io == NULL && !client->disconnected) {
+		client->io = io_add(client->fd_in,
 				    IO_READ, _client_input, client);
 	}
 }