[asterisk-commits] russell: trunk r115521 - /trunk/res/res_config_ldap.c
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Wed May 7 13:30:12 CDT 2008
Author: russell
Date: Wed May 7 13:30:12 2008
New Revision: 115521
URL: http://svn.digium.com/view/asterisk?view=rev&rev=115521
Log:
Use the default that the log output claims will be used for the basedn
(closes issue #12599)
Reported by: suretec
Patches:
12599.patch uploaded by juggie (license 24)
Modified:
trunk/res/res_config_ldap.c
Modified: trunk/res/res_config_ldap.c
URL: http://svn.digium.com/view/asterisk/trunk/res/res_config_ldap.c?view=diff&rev=115521&r1=115520&r2=115521
==============================================================================
--- trunk/res/res_config_ldap.c (original)
+++ trunk/res/res_config_ldap.c Wed May 7 13:30:12 2008
@@ -58,6 +58,7 @@
#include "asterisk/linkedlists.h"
#define RES_CONFIG_LDAP_CONF "res_ldap.conf"
+#define RES_CONFIG_LDAP_DEFAULT_BASEDN "asterisk"
AST_MUTEX_DEFINE_STATIC(ldap_lock);
@@ -1423,8 +1424,8 @@
}
if (!(s = ast_variable_retrieve(config, "_general", "basedn"))) {
- ast_log(LOG_ERROR, "No LDAP base dn found, using 'asterisk' as default.\n");
- basedn[0] = '\0';
+ ast_log(LOG_ERROR, "No LDAP base dn found, using '%s' as default.\n", RES_CONFIG_LDAP_DEFAULT_BASEDN);
+ ast_copy_string(basedn, RES_CONFIG_LDAP_DEFAULT_BASEDN, sizeof(basedn));
} else
ast_copy_string(basedn, s, sizeof(basedn));
More information about the asterisk-commits
mailing list