5c0901a
diff -up cyrus-sasl-2.1.26/plugins/gssapi.c.release-server_creds cyrus-sasl-2.1.26/plugins/gssapi.c
5c0901a
--- cyrus-sasl-2.1.26/plugins/gssapi.c.release-server_creds	2012-12-20 17:17:37.000000000 +0100
5c0901a
+++ cyrus-sasl-2.1.26/plugins/gssapi.c	2012-12-20 17:42:11.498138999 +0100
5c0901a
@@ -945,6 +945,12 @@ gssapi_server_mech_authneg(context_t *te
5c0901a
 	ret = SASL_CONTINUE;
5c0901a
     }
5c0901a
 
5c0901a
+    /* Release server creds which are no longer needed */
5c0901a
+     if ( text->server_creds != GSS_C_NO_CREDENTIAL) {
5c0901a
+        maj_stat = gss_release_cred(&min_stat, &text->server_creds);
5c0901a
+        text->server_creds = GSS_C_NO_CREDENTIAL;
5c0901a
+     }
5c0901a
+
5c0901a
   cleanup:
5c0901a
     if (client_name_MN) {
5c0901a
 	GSS_LOCK_MUTEX(params->utils);