[Commits] [SCM] claws branch, master, updated. 3.16.0-85-g6dcf9b1

ticho at claws-mail.org ticho at claws-mail.org
Sat Mar 3 18:08:04 CET 2018


The branch, master has been updated
       via  6dcf9b1c9fc3c6d72f1c88f321772afa58224b63 (commit)
      from  3f581b09bfd34d5ba746f5597fd0fb9485ab00c9 (commit)

Summary of changes:
 src/ldapquery.c  |    8 ++++----
 src/ldapserver.c |   15 +++++++--------
 src/ldaputil.c   |    4 ++--
 3 files changed, 13 insertions(+), 14 deletions(-)


- Log -----------------------------------------------------------------
commit 6dcf9b1c9fc3c6d72f1c88f321772afa58224b63
Author: Andrej Kacian <ticho at claws-mail.org>
Date:   Sat Mar 3 18:05:52 2018 +0100

    Make LDAP use log_print instead of log_message for uninteresting stuff.
    
    This makes it less noisy on the console without --debug if
    everything works OK.

diff --git a/src/ldapquery.c b/src/ldapquery.c
index 7f0d293..b132989 100644
--- a/src/ldapquery.c
+++ b/src/ldapquery.c
@@ -746,7 +746,7 @@ static gint ldapqry_disconnect( LdapQuery *qry ) {
 			log_error(LOG_PROTOCOL, _("LDAP error (unbind): %d (%s)\n"),
 					rc, ldaputil_get_error(qry->ldap));
 		} else {
-			log_message(LOG_PROTOCOL, _("LDAP (unbind): successful\n"));
+			log_print(LOG_PROTOCOL, _("LDAP (unbind): successful\n"));
 		}
 	}
 	qry->ldap = NULL;
@@ -821,11 +821,11 @@ static gint ldapqry_search_retrieve( LdapQuery *qry ) {
 		searchFlag = TRUE;
 	}
 	else if( rc == LDAP_SUCCESS ) {
-		log_message(LOG_PROTOCOL, _("LDAP (search): successful\n"));
+		log_print(LOG_PROTOCOL, _("LDAP (search): successful\n"));
 		searchFlag = TRUE;
 	}
 	else if( rc == LDAP_PARTIAL_RESULTS || (result && ldap_count_entries(ld, result) > 0) ) {
-		log_message(LOG_PROTOCOL, _("LDAP (search): successful (partial results)\n"));
+		log_print(LOG_PROTOCOL, _("LDAP (search): successful (partial results)\n"));
 		searchFlag = TRUE;
 	}
 	else {
@@ -1236,7 +1236,7 @@ static gint ldapqry_locate_retrieve( LdapQuery *qry ) {
 				rc, ldaputil_get_error(ld));
 		return ADDRQUERY_RETVAL(qry);
 	} else {
-		log_message(LOG_PROTOCOL, _("LDAP (search): successful\n"));
+		log_print(LOG_PROTOCOL, _("LDAP (search): successful\n"));
 	}
 
 #ifdef G_OS_WIN32
diff --git a/src/ldapserver.c b/src/ldapserver.c
index a05c07c..831dd48 100644
--- a/src/ldapserver.c
+++ b/src/ldapserver.c
@@ -758,7 +758,6 @@ PFldap_start_tls_s Win32_ldap_start_tls_s = NULL;
 LDAP *ldapsvr_connect(LdapControl *ctl) {
 	LDAP *ld = NULL;
 	gint rc;
-	gint op;
 	gint version;
 	gchar *uri = NULL;
 	gchar *pwd;
@@ -780,7 +779,7 @@ LDAP *ldapsvr_connect(LdapControl *ctl) {
 		rc = ldap_set_option(ld, LDAP_OPT_PROTOCOL_VERSION, (void *)&version);
 		if (rc == LDAP_SUCCESS) {
 			ctl->version = LDAP_VERSION3;
-			log_message(LOG_PROTOCOL, "LDAP (options): set version 3\n");
+			log_print(LOG_PROTOCOL, "LDAP (options): set version 3\n");
 		} else {
 			log_error(LOG_PROTOCOL, _("LDAP error (options): %d (%s)\n"),
 					rc, ldaputil_get_error(ld));
@@ -807,7 +806,7 @@ LDAP *ldapsvr_connect(LdapControl *ctl) {
 					log_error(LOG_PROTOCOL, _("LDAP error (options): %d (%s)\n"),
 							rc, ldaputil_get_error(ld));
 				} else {
-					log_message(LOG_PROTOCOL, _("LDAP (options): SSL/TLS enabled (%d)\n"), op);
+					log_print(LOG_PROTOCOL, _("LDAP (options): SSL/TLS enabled (%d)\n"), op);
 				}
 				debug_print("SSL/TLS now %d\n", op);
 			}
@@ -818,7 +817,7 @@ LDAP *ldapsvr_connect(LdapControl *ctl) {
 					rc, ldaputil_get_error(ld));
 			debug_print("ldap_connect failed: %d %s\n", rc, ldaputil_get_error(ld));
 		} else {
-			log_message(LOG_PROTOCOL, _("LDAP (connect): completed successfully\n"));
+			log_print(LOG_PROTOCOL, _("LDAP (connect): completed successfully\n"));
 		}
 	}
 #endif
@@ -834,7 +833,7 @@ LDAP *ldapsvr_connect(LdapControl *ctl) {
 	rc = ldap_set_option(ld, LDAP_OPT_PROTOCOL_VERSION, &version);
 	if (rc == LDAP_OPT_SUCCESS) {
 		ctl->version = LDAP_VERSION3;
-		log_message(LOG_PROTOCOL, "LDAP (options): set version 3\n");
+		log_print(LOG_PROTOCOL, "LDAP (options): set version 3\n");
 	} else {
 		log_error(LOG_PROTOCOL, _("LDAP error (options): %d (%s)\n"),
 				rc, ldaputil_get_error(ld));
@@ -869,7 +868,7 @@ LDAP *ldapsvr_connect(LdapControl *ctl) {
 						rc, ldaputil_get_error(ld));
 				return NULL;
 			} else {
-				log_message(LOG_PROTOCOL, _("LDAP (TLS): started successfully\n"));
+				log_print(LOG_PROTOCOL, _("LDAP (TLS): started successfully\n"));
 				debug_print("Done\n");
 			}
 		}
@@ -889,7 +888,7 @@ LDAP *ldapsvr_connect(LdapControl *ctl) {
 						ctl->bindDN, rc, ldaputil_get_error(ld));
 				return NULL;
 			}
-			log_message(LOG_PROTOCOL, _("LDAP (bind): successfully for DN '%s'\n"),
+			log_print(LOG_PROTOCOL, _("LDAP (bind): successfully for DN '%s'\n"),
 					ctl->bindDN);
 		}
 	}
@@ -909,7 +908,7 @@ void ldapsvr_disconnect(LDAP *ld) {
 		log_error(LOG_PROTOCOL, _("LDAP error (unbind): %d (%s)\n"),
 				rc, ldaputil_get_error(ld));
 	} else {
-		log_message(LOG_PROTOCOL, _("LDAP (unbind): successful\n"));
+		log_print(LOG_PROTOCOL, _("LDAP (unbind): successful\n"));
 	}
 }
 
diff --git a/src/ldaputil.c b/src/ldaputil.c
index 1be1854..983e970 100644
--- a/src/ldaputil.c
+++ b/src/ldaputil.c
@@ -78,7 +78,7 @@ static GList *ldaputil_test_v3( LDAP *ld, gint tov, gint *errcode ) {
 		attribs, 0, NULL, NULL, &timeout, 0, &result );
 
 	if( rc == LDAP_SUCCESS ) {
-		log_message(LOG_PROTOCOL, _("LDAP (search): succesful\n"));
+		log_print(LOG_PROTOCOL, _("LDAP (search): succesful\n"));
 		/* Process entries */
 		for( e = ldap_first_entry( ld, result );
 		     e != NULL;
@@ -153,7 +153,7 @@ static GList *ldaputil_test_v2( LDAP *ld, gint tov ) {
 		attribs, 0, NULL, NULL, &timeout, 0, &result );
 
 	if( rc == LDAP_SUCCESS ) {
-		log_message(LOG_PROTOCOL, _("LDAP (search): succesful\n"));
+		log_print(LOG_PROTOCOL, _("LDAP (search): succesful\n"));
 		/* Process entries */
 		for( e = ldap_first_entry( ld, result );
 		     e != NULL;

-----------------------------------------------------------------------


hooks/post-receive
-- 
Claws Mail


More information about the Commits mailing list