summaryrefslogtreecommitdiff
path: root/src/core/core-secure-config.c
diff options
context:
space:
mode:
authorSébastien Helleu <flashcode@flashtux.org>2024-04-01 21:44:42 +0200
committerSébastien Helleu <flashcode@flashtux.org>2024-04-01 21:48:11 +0200
commit7e997f87e80e3583480bb78ac6b094bda0ef012f (patch)
tree3e294b63757a7047e275cfc6228d341dd5887540 /src/core/core-secure-config.c
parent965beb37dede0ac0f6e1be961acfbc15ee7e46cf (diff)
downloadweechat-7e997f87e80e3583480bb78ac6b094bda0ef012f.zip
core: add cast to "const char *" for hashtable value
Diffstat (limited to 'src/core/core-secure-config.c')
-rw-r--r--src/core/core-secure-config.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/core/core-secure-config.c b/src/core/core-secure-config.c
index 908628edf..034362645 100644
--- a/src/core/core-secure-config.c
+++ b/src/core/core-secure-config.c
@@ -422,7 +422,7 @@ secure_config_data_write_map_cb (void *data,
{
/* encrypt password using passphrase */
rc = secure_encrypt_data (
- value, strlen (value) + 1,
+ (const char *)value, strlen ((const char *)value) + 1,
hash_algo,
cipher,
secure_passphrase,
@@ -457,7 +457,8 @@ secure_config_data_write_map_cb (void *data,
else
{
/* store password as plain text */
- config_file_write_line (config_file, key, "\"%s\"", value);
+ config_file_write_line (config_file, key,
+ "\"%s\"", (const char *)value);
}
}
@@ -478,7 +479,7 @@ secure_config_data_write_map_encrypted_cb (void *data,
config_file = (struct t_config_file *)data;
/* store data as-is (it is already encrypted) */
- config_file_write_line (config_file, key, "\"%s\"", value);
+ config_file_write_line (config_file, key, "\"%s\"", (const char *)value);
}
/*