diff src/protocols/silc/ops.c @ 10336:114d3ac8ff5a

[gaim-migrate @ 11543] This should fix public key authentication for SILC if your key is password protected. It's a patch from Michele Baldessari. committer: Tailor Script <tailor@pidgin.im>
author Mark Doliner <mark@kingant.net>
date Thu, 09 Dec 2004 03:10:30 +0000
parents a66cf83552dc
children 0f7452b1f777
line wrap: on
line diff
--- a/src/protocols/silc/ops.c	Thu Dec 09 02:55:18 2004 +0000
+++ b/src/protocols/silc/ops.c	Thu Dec 09 03:10:30 2004 +0000
@@ -1601,15 +1601,15 @@
 
 	/* Check configuration if we have this connection configured.  If we
 	   have then return that data immediately, as it's faster way. */
+	if (gaim_account_get_bool(sg->account, "pubkey-auth", FALSE)) {
+		completion(TRUE, SILC_AUTH_PUBLIC_KEY, NULL, 0, context);
+		return;
+	}
 	if (gc->account->password && *gc->account->password) {
 		completion(TRUE, SILC_AUTH_PASSWORD, gc->account->password,
 			   strlen(gc->account->password), context);
 		return;
 	}
-	if (gaim_account_get_bool(sg->account, "pubkey-auth", FALSE)) {
-		completion(TRUE, SILC_AUTH_PUBLIC_KEY, NULL, 0, context);
-		return;
-	}
 
 	/* Resolve the authentication method from server, as we may not know it. */
 	internal = silc_calloc(1, sizeof(*internal));