[dovecot-cvs] dovecot/src/imap-login client-authenticate.c, 1.38,
1.39 client.c, 1.48, 1.49
cras at dovecot.org
cras at dovecot.org
Sat Jan 28 23:47:04 EET 2006
- Previous message: [dovecot-cvs] dovecot/src/pop3-login client-authenticate.c, 1.46,
1.47 client.c, 1.47, 1.48
- Next message: [dovecot-cvs] dovecot/src/lib-storage/index/dbox Makefile.am, 1.2,
1.3 dbox-file.c, 1.4, 1.5 dbox-file.h, 1.1,
1.2 dbox-keywords.c, NONE, 1.1 dbox-keywords.h, NONE,
1.1 dbox-mail.c, 1.4, 1.5 dbox-storage.h, 1.5,
1.6 dbox-sync-full.c, 1.2, 1.3 dbox-sync.c, 1.5,
1.6 dbox-uidlist.c, 1.13, 1.14
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /var/lib/cvs/dovecot/src/imap-login
In directory talvi:/tmp/cvs-serv21074/imap-login
Modified Files:
client-authenticate.c client.c
Log Message:
If client disconnected while we were trying to send authentication
continuation to it, we crashed.
Index: client-authenticate.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/imap-login/client-authenticate.c,v
retrieving revision 1.38
retrieving revision 1.39
diff -u -d -r1.38 -r1.39
--- client-authenticate.c 14 Jan 2006 18:47:22 -0000 1.38
+++ client-authenticate.c 28 Jan 2006 21:47:00 -0000 1.39
@@ -179,7 +179,6 @@
struct imap_client *client = (struct imap_client *)_client;
struct const_iovec iov[3];
size_t data_len;
- ssize_t ret;
switch (reply) {
case SASL_SERVER_REPLY_SUCCESS:
@@ -217,16 +216,10 @@
iov[2].iov_base = "\r\n";
iov[2].iov_len = 2;
- ret = o_stream_sendv(client->output, iov, 3);
- if (ret < 0)
- client_destroy(client, "Disconnected");
- else if ((size_t)ret != 2 + data_len + 2)
- client_destroy(client, "Transmit buffer full");
- else {
- /* continue */
- return;
- }
- break;
+ /* don't check return value here. it gets tricky if we try
+ to call client_destroy() in here. */
+ (void)o_stream_sendv(client->output, iov, 3);
+ return;
}
client_unref(client);
Index: client.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/imap-login/client.c,v
retrieving revision 1.48
retrieving revision 1.49
diff -u -d -r1.48 -r1.49
--- client.c 28 Jan 2006 21:28:16 -0000 1.48
+++ client.c 28 Jan 2006 21:47:00 -0000 1.49
@@ -519,6 +519,7 @@
bool client_unref(struct imap_client *client)
{
+ i_assert(client->refcount > 0);
if (--client->refcount > 0)
return TRUE;
- Previous message: [dovecot-cvs] dovecot/src/pop3-login client-authenticate.c, 1.46,
1.47 client.c, 1.47, 1.48
- Next message: [dovecot-cvs] dovecot/src/lib-storage/index/dbox Makefile.am, 1.2,
1.3 dbox-file.c, 1.4, 1.5 dbox-file.h, 1.1,
1.2 dbox-keywords.c, NONE, 1.1 dbox-keywords.h, NONE,
1.1 dbox-mail.c, 1.4, 1.5 dbox-storage.h, 1.5,
1.6 dbox-sync-full.c, 1.2, 1.3 dbox-sync.c, 1.5,
1.6 dbox-uidlist.c, 1.13, 1.14
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the dovecot-cvs
mailing list