pidgin: 6729857f: Don't try to write a cert with a blank f...

darkrain42 at darkrain42 at
Sat Aug 15 23:25:54 EDT 2009

Revision: 6729857f5490c9709931695c7a2bd8557f6eb832
Ancestor: e908345ac1772ff13e4f847653151463ee52c50d
Author: darkrain42 at
Date: 2009-08-16T03:21:47
Branch: im.pidgin.pidgin

Modified files:


Don't try to write a cert with a blank filename.

This *should* throw an error, probably, but I'm lazy. This is better
than the previous behavior.

-------------- next part --------------
--- pidgin/gtkcertmgr.c	3674d143f8aad533d43076c27bbb06ba72c0afa0
+++ pidgin/gtkcertmgr.c	ab17d6fb5dd2ac6d7a213f3b1395f59593ec6d7f
@@ -144,12 +144,12 @@ tls_peers_mgmt_import_ok2_cb(gpointer da
 tls_peers_mgmt_import_ok2_cb(gpointer data, const char *result)
 	PurpleCertificate *crt = (PurpleCertificate *) data;
-	const char *id = result;
 	/* TODO: Perhaps prompt if you're overwriting a cert? */
 	/* Drop the certificate into the pool */
-	purple_certificate_pool_store(tpm_dat->tls_peers, id, crt);
+	if (result && *result)
+		purple_certificate_pool_store(tpm_dat->tls_peers, result, crt);
 	/* And this certificate is not needed any more */

More information about the Commits mailing list