summaryrefslogtreecommitdiff
path: root/src/core/wee-network.c
diff options
context:
space:
mode:
authorSébastien Helleu <flashcode@flashtux.org>2021-06-17 21:51:18 +0200
committerSébastien Helleu <flashcode@flashtux.org>2021-06-17 21:51:18 +0200
commit2225ac4e56289b1badc7a5ee9dcb522b8e8aa3f2 (patch)
treecada0254e77311ce9168e428eaf9fc6e3ee7d1aa /src/core/wee-network.c
parentfa785e8668b51f80e112c7c927648635b2d4f565 (diff)
downloadweechat-2225ac4e56289b1badc7a5ee9dcb522b8e8aa3f2.zip
core: add option "certs" in command /debug
Diffstat (limited to 'src/core/wee-network.c')
-rw-r--r--src/core/wee-network.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/core/wee-network.c b/src/core/wee-network.c
index 13371a61d..8e235c983 100644
--- a/src/core/wee-network.c
+++ b/src/core/wee-network.c
@@ -68,6 +68,9 @@
int network_init_gnutls_ok = 0;
+
+int network_num_certs_system = 0; /* number of system certs loaded */
+int network_num_certs_user = 0; /* number of user certs loaded */
int network_num_certs = 0; /* number of certs loaded (system + user) */
gnutls_certificate_credentials_t gnutls_xcred; /* GnuTLS client credentials */
@@ -125,6 +128,8 @@ network_load_system_ca_file (int force_display)
rc);
}
+ network_num_certs_system = rc;
+
return rc;
}
@@ -212,6 +217,8 @@ end:
if (options)
hashtable_free (options);
+ network_num_certs_user = num_loaded;
+
return num_loaded;
}
@@ -225,6 +232,8 @@ network_load_ca_files (int force_display)
if (weechat_no_gnutls)
return;
+ network_num_certs_system = 0;
+ network_num_certs_user = 0;
network_num_certs = 0;
network_num_certs += network_load_system_ca_file (force_display);