adium 3531:d254fa9daa25: Fixed debug logging not to go to Console

commits at adium.im commits at adium.im
Tue Nov 16 01:01:27 UTC 2010


details:	http://hg.adium.im/adium/rev/d254fa9daa25
revision:	3531:d254fa9daa25
author:		Evan Schoenberg
date:		Mon Nov 15 18:33:19 2010 -0600

Fixed debug logging not to go to Console
(transplanted from 1750cad4240737c38724016b18e557f8b849b87c)
Subject: adium 3532:9a398860e182: Disable connecting via SSL to ICQ

details:	http://hg.adium.im/adium/rev/9a398860e182
revision:	3532:9a398860e182
author:		Evan Schoenberg
date:		Mon Nov 15 18:39:03 2010 -0600

Disable connecting via SSL to ICQ
(transplanted from ce0971e07ac63a6c59b58ccc03ea5708a192d7e0)

diffs (98 lines):

diff -r 0a658933d3ad -r 9a398860e182 Plugins/Purple Service/ESPurpleICQAccount.m
--- a/Plugins/Purple Service/ESPurpleICQAccount.m	Mon Nov 15 15:00:47 2010 +0100
+++ b/Plugins/Purple Service/ESPurpleICQAccount.m	Mon Nov 15 18:39:03 2010 -0600
@@ -29,8 +29,11 @@
 
 - (void)initAccount
 {
-	if ([[self preferenceForKey:KEY_CONNECT_HOST group:GROUP_ACCOUNT_STATUS] caseInsensitiveCompare:@"login.oscar.aol.com"] == NSOrderedSame) {
-		/* Reset to the default if we're set to the old AOL login server */
+	if (([[self preferenceForKey:KEY_CONNECT_HOST group:GROUP_ACCOUNT_STATUS] caseInsensitiveCompare:@"login.oscar.aol.com"] == NSOrderedSame) ||
+		([[self preferenceForKey:KEY_CONNECT_HOST group:GROUP_ACCOUNT_STATUS] caseInsensitiveCompare:@"slogin.oscar.aol.com"] == NSOrderedSame) ||
+		([[self preferenceForKey:KEY_CONNECT_HOST group:GROUP_ACCOUNT_STATUS] caseInsensitiveCompare:@"slogin.icq.com"] == NSOrderedSame) {
+		/* Reset to the default if we're set to the old AOL login server or its ssl variant.
+		 * Reset to the default if we're set to use the ICQ SSL server, as it's currently broken. */
 		[self setPreference:nil
 					 forKey:KEY_CONNECT_HOST
 					  group:GROUP_ACCOUNT_STATUS];
@@ -55,8 +58,12 @@
 	
 	//Defaults to NO - web_aware will cause lots of spam for many users!
 	purple_account_set_bool(account, "web_aware", [[self preferenceForKey:KEY_ICQ_WEB_AWARE group:GROUP_ACCOUNT_STATUS] boolValue]);
+
+#warning Remove when ICQ SSL support is fixed
+	purple_account_set_bool(account, "use_ssl", NO);
 }
 
+
 #pragma mark Contact updates
 
 - (const char *)purpleStatusIDForStatus:(AIStatus *)statusState
diff -r 0a658933d3ad -r 9a398860e182 Plugins/Purple Service/ESPurpleICQAccountViewController.m
--- a/Plugins/Purple Service/ESPurpleICQAccountViewController.m	Mon Nov 15 15:00:47 2010 +0100
+++ b/Plugins/Purple Service/ESPurpleICQAccountViewController.m	Mon Nov 15 18:39:03 2010 -0600
@@ -32,6 +32,7 @@
 	[popUp_encoding setMenu:[self encodingMenu]];
 }
 
+
 //Configure controls
 - (void)configureForAccount:(AIAccount *)inAccount
 {
@@ -40,6 +41,10 @@
 																		group:GROUP_ACCOUNT_STATUS]];
 	[checkBox_webAware setState:[[account preferenceForKey:KEY_ICQ_WEB_AWARE
 													 group:GROUP_ACCOUNT_STATUS] boolValue]];
+
+#warning Remove when ICQ SSL support is fixed
+	[checkBox_SSL setState:NO];
+	[checkBox_SSL setEnabled:NO];
 }
 
 //Save controls
diff -r 0a658933d3ad -r 9a398860e182 Plugins/Purple Service/SLPurpleCocoaAdapter.m
--- a/Plugins/Purple Service/SLPurpleCocoaAdapter.m	Mon Nov 15 15:00:47 2010 +0100
+++ b/Plugins/Purple Service/SLPurpleCocoaAdapter.m	Mon Nov 15 18:39:03 2010 -0600
@@ -166,7 +166,7 @@
 
 - (void)debugLoggingIsEnabledDidChange:(NSNotification *)inNotification
 {
-	purple_debug_set_enabled(AIDebugLoggingIsEnabled());
+	configurePurpleDebugLogging();
 }
 
 - (void)initLibPurple
diff -r 0a658933d3ad -r 9a398860e182 Plugins/Purple Service/adiumPurpleCore.h
--- a/Plugins/Purple Service/adiumPurpleCore.h	Mon Nov 15 15:00:47 2010 +0100
+++ b/Plugins/Purple Service/adiumPurpleCore.h	Mon Nov 15 18:39:03 2010 -0600
@@ -17,3 +17,5 @@
 #import <AdiumLibpurple/SLPurpleCocoaAdapter.h>
 
 PurpleCoreUiOps *adium_purple_core_get_ops(void);
+
+void configurePurpleDebugLogging();
diff -r 0a658933d3ad -r 9a398860e182 Plugins/Purple Service/adiumPurpleCore.m
--- a/Plugins/Purple Service/adiumPurpleCore.m	Mon Nov 15 15:00:47 2010 +0100
+++ b/Plugins/Purple Service/adiumPurpleCore.m	Mon Nov 15 18:39:03 2010 -0600
@@ -137,12 +137,17 @@
 	purple_buddy_icons_set_caching(TRUE);	
 }
 
+void configurePurpleDebugLogging()
+{
+	purple_debug_set_ui_ops(AIDebugLoggingIsEnabled() ?
+							adium_purple_debug_get_ui_ops() :
+							NULL);
+}
+
 static void adiumPurpleCoreDebugInit(void)
 {
-	AILog(@"adiumPurpleCoreDebugInit()");
-    purple_debug_set_ui_ops(adium_purple_debug_get_ui_ops());
-
-	purple_debug_set_enabled(AIDebugLoggingIsEnabled());
+	AILogWithSignature(@"");
+	configurePurpleDebugLogging();
 }
 
 static void associateLibpurpleAccounts(void)




More information about the commits mailing list