changeset 3386:e4b84d82c685 HEAD

Master connection's USER command was leaking memory (with deliver binary).
author Timo Sirainen <tss@iki.fi>
date Tue, 17 May 2005 12:34:38 +0300
parents fe4a297379fc
children bfb2658a2616
files src/auth/auth-master-connection.c src/auth/auth-request.c
diffstat 2 files changed, 5 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/auth/auth-master-connection.c	Tue May 17 00:00:45 2005 +0300
+++ b/src/auth/auth-master-connection.c	Tue May 17 12:34:38 2005 +0300
@@ -91,6 +91,7 @@
 		str_append_c(str, '\n');
 	}
 	(void)o_stream_send(conn->output, str_data(str), str_len(str));
+	auth_request_unref(auth_request);
 }
 
 static int
--- a/src/auth/auth-request.c	Tue May 17 00:00:45 2005 +0300
+++ b/src/auth/auth-request.c	Tue May 17 12:34:38 2005 +0300
@@ -91,7 +91,10 @@
 	if (--request->refcount > 0)
 		return TRUE;
 
-	request->mech->auth_free(request);
+	if (request->mech != NULL)
+		request->mech->auth_free(request);
+	else
+		pool_unref(request->pool);
 	return FALSE;
 }