summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSébastien Helleu <flashcode@flashtux.org>2023-06-27 12:56:42 +0200
committerSébastien Helleu <flashcode@flashtux.org>2023-06-27 12:58:34 +0200
commitfc41ad336d6e2494d5291d97030627fc7bc5d506 (patch)
treea67afbfa4bc9513d4cfd44edd558bd7063207ae9 /src
parent1d4509ddd88a91efd3b6420cc2af6b6d0246af5f (diff)
downloadweechat-fc41ad336d6e2494d5291d97030627fc7bc5d506.zip
api: do not convert option name to lower case in API functions config_set_plugin and config_set_desc_plugin
Diffstat (limited to 'src')
-rw-r--r--src/plugins/plugin-config.c19
1 files changed, 4 insertions, 15 deletions
diff --git a/src/plugins/plugin-config.c b/src/plugins/plugin-config.c
index 14f717439..4e318e3da 100644
--- a/src/plugins/plugin-config.c
+++ b/src/plugins/plugin-config.c
@@ -114,7 +114,7 @@ plugin_config_set (const char *plugin_name, const char *option_name,
const char *value)
{
int length, rc;
- char *option_full_name, *option_full_name_lower;
+ char *option_full_name;
rc = WEECHAT_CONFIG_OPTION_SET_ERROR;
@@ -124,12 +124,7 @@ plugin_config_set (const char *plugin_name, const char *option_name,
{
snprintf (option_full_name, length, "%s.%s",
plugin_name, option_name);
- option_full_name_lower = string_tolower (option_full_name);
- if (option_full_name_lower)
- {
- rc = plugin_config_set_internal (option_full_name_lower, value);
- free (option_full_name_lower);
- }
+ rc = plugin_config_set_internal (option_full_name, value);
free (option_full_name);
}
@@ -206,7 +201,7 @@ plugin_config_set_desc (const char *plugin_name, const char *option_name,
const char *description)
{
int length;
- char *option_full_name, *option_full_name_lower;
+ char *option_full_name;
length = strlen (plugin_name) + 1 + strlen (option_name) + 1;
option_full_name = malloc (length);
@@ -214,13 +209,7 @@ plugin_config_set_desc (const char *plugin_name, const char *option_name,
{
snprintf (option_full_name, length, "%s.%s",
plugin_name, option_name);
- option_full_name_lower = string_tolower (option_full_name);
- if (option_full_name_lower)
- {
- plugin_config_set_desc_internal (option_full_name_lower,
- description);
- free (option_full_name_lower);
- }
+ plugin_config_set_desc_internal (option_full_name, description);
free (option_full_name);
}
}