Blame SOURCES/cyrus-sasl-2.1.27-Emit-debug-log-only-in-case-of-errors.patch

8b8af0
From ec070b2e83a4ee698c08d6d68c205aea4d90b0bb Mon Sep 17 00:00:00 2001
8b8af0
From: Simo Sorce <simo@redhat.com>
8b8af0
Date: Tue, 5 May 2020 14:31:10 -0400
8b8af0
Subject: [PATCH] Emit debug log only in case of errors
8b8af0
8b8af0
Backport of commit id:
8b8af0
ccc5e547d4b40ee2b182a9945f8f6cc10b4fdf48
8b8af0
8b8af0
Signed-off-by: Simo Sorce <simo@redhat.com>
8b8af0
---
8b8af0
 plugins/gssapi.c | 7 +++----
8b8af0
 1 file changed, 3 insertions(+), 4 deletions(-)
8b8af0
8b8af0
diff --git a/plugins/gssapi.c b/plugins/gssapi.c
8b8af0
index 7480316..6bcd78e 100644
8b8af0
--- a/plugins/gssapi.c
8b8af0
+++ b/plugins/gssapi.c
8b8af0
@@ -1444,9 +1444,6 @@ gssapi_server_mech_step(void *conn_context,
8b8af0
 
8b8af0
     if (text == NULL) return SASL_BADPROT;
8b8af0
 
8b8af0
-    params->utils->log(params->utils->conn, SASL_LOG_DEBUG,
8b8af0
-		       "GSSAPI server step %d\n", text->state);
8b8af0
-
8b8af0
     switch (text->state) {
8b8af0
 
8b8af0
     case SASL_GSSAPI_STATE_AUTHNEG:
8b8af0
@@ -1496,8 +1493,10 @@ gssapi_server_mech_step(void *conn_context,
8b8af0
 	}
8b8af0
 
8b8af0
 	oparams->doneflag = 1;
8b8af0
+    } else {
8b8af0
+        params->utils->log(params->utils->conn, SASL_LOG_DEBUG,
8b8af0
+		           "GSSAPI server step failed: %d\n", text->state);
8b8af0
     }
8b8af0
-    
8b8af0
     return ret;
8b8af0
 }
8b8af0
 
8b8af0
-- 
8b8af0
2.18.2
8b8af0