[Dovecot] two little fixes for 2.0.14

Mike Abbott michael.abbott at apple.com
Tue Sep 13 02:00:51 EEST 2011


--- a/dovecot/src/lib-index/mail-index-view.c
+++ b/dovecot/src/lib-index/mail-index-view.c
@@ -9,7 +9,7 @@
 void mail_index_view_clone(struct mail_index_view *dest,
 			   const struct mail_index_view *src)
 {
-	memset(dest, 0, sizeof(dest));
+	memset(dest, 0, sizeof(*dest));
 	dest->refcount = 1;
 	dest->v = src->v;
 	dest->index = src->index;


--- a/dovecot/src/lib-storage/mail-storage-service.c
+++ b/dovecot/src/lib-storage/mail-storage-service.c
@@ -870,7 +870,7 @@
 	}
 
 	user = p_new(user_pool, struct mail_storage_service_user, 1);
-	memset(user_r, 0, sizeof(user_r));
+	memset(user_r, 0, sizeof(*user_r));
 	user->pool = user_pool;
 	user->input = *input;
 	user->input.userdb_fields = NULL;




More information about the dovecot mailing list