aboutsummaryrefslogtreecommitdiffstats
path: root/res/res_config_ldap.c
diff options
context:
space:
mode:
authortwilson <twilson@f38db490-d61c-443f-a65b-d21fe96a405b>2008-03-18 15:43:34 +0000
committertwilson <twilson@f38db490-d61c-443f-a65b-d21fe96a405b>2008-03-18 15:43:34 +0000
commit9e8ebe6a94eb44796b296dfc214622ac583d4630 (patch)
treea07721daf3a91733bc3e073bab0697333d426e21 /res/res_config_ldap.c
parent421d5fe68591bbafcf04602c3bba927cac40a2a9 (diff)
Go through and fix a bunch of places where character strings were being interpreted as format strings. Most of these changes are solely to make compiling with -Wsecurity and -Wformat=2 happy, and were not
actual problems, per se. I also added format attributes to any printf wrapper functions I found that didn't have them. -Wsecurity and -Wmissing-format-attribute added to --enable-dev-mode. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@109447 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'res/res_config_ldap.c')
-rw-r--r--res/res_config_ldap.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/res/res_config_ldap.c b/res/res_config_ldap.c
index b76ad8ae7..028902adb 100644
--- a/res/res_config_ldap.c
+++ b/res/res_config_ldap.c
@@ -766,10 +766,10 @@ static struct ast_variable **realtime_ldap_base_ap(unsigned int *entries_count_p
ast_str_append(&filter, 0, "(&");
if (table_config && table_config->additional_filter)
- ast_str_append(&filter, 0, table_config->additional_filter);
+ ast_str_append(&filter, 0, "%s", table_config->additional_filter);
if (table_config != base_table_config && base_table_config &&
base_table_config->additional_filter) {
- ast_str_append(&filter, 0, base_table_config->additional_filter);
+ ast_str_append(&filter, 0, "%s", base_table_config->additional_filter);
}
/* Create the first part of the query using the first parameter/value pairs we just extracted */
@@ -1171,11 +1171,11 @@ static int update_ldap(const char *basedn, const char *table_name, const char *a
/* Create the filter with the table additional filter and the parameter/value pairs we were given */
ast_str_append(&filter, 0, "(&");
if (table_config && table_config->additional_filter) {
- ast_str_append(&filter, 0, table_config->additional_filter);
+ ast_str_append(&filter, 0, "%s", table_config->additional_filter);
}
if (table_config != base_table_config && base_table_config
&& base_table_config->additional_filter) {
- ast_str_append(&filter, 0, base_table_config->additional_filter);
+ ast_str_append(&filter, 0, "%s", base_table_config->additional_filter);
}
append_var_and_value_to_filter(&filter, table_config, attribute, lookup);
ast_str_append(&filter, 0, ")");