Cleanup char* to auto_gchar gchar* for prefs_get_string

Necessity explained in #1819
This commit is contained in:
John Hernandez
2023-06-13 22:01:08 +02:00
parent 1c102fec27
commit 4a70f5f513
19 changed files with 133 additions and 275 deletions

View File

@@ -131,7 +131,7 @@ http_file_get(void* userdata)
goto out;
}
char* cert_path = prefs_get_string(PREF_TLS_CERTPATH);
gchar* cert_path = prefs_get_string(PREF_TLS_CERTPATH);
gchar* cafile = cafile_get_name();
ProfAccount* account = accounts_get_account(session_get_account_name());
gboolean insecure = account->tls_policy && strcmp(account->tls_policy, "trust") == 0;

View File

@@ -184,7 +184,7 @@ http_file_put(void* userdata)
win_print_http_transfer(upload->window, msg, upload->put_url);
g_free(msg);
char* cert_path = prefs_get_string(PREF_TLS_CERTPATH);
auto_gchar gchar* cert_path = prefs_get_string(PREF_TLS_CERTPATH);
gchar* cafile = cafile_get_name();
ProfAccount* account = accounts_get_account(session_get_account_name());
gboolean insecure = account->tls_policy && strcmp(account->tls_policy, "trust") == 0;
@@ -301,7 +301,6 @@ http_file_put(void* userdata)
pthread_mutex_lock(&lock);
g_free(cafile);
g_free(cert_path);
if (err) {
gchar* msg;