File bnc653852-kopete-icq-server-change.diff of Package kdenetwork4
Index: kopete/protocols/oscar/icq/icqaccount.cpp
===================================================================
--- kopete/protocols/oscar/icq/icqaccount.cpp (revision 1197798)
+++ kopete/protocols/oscar/icq/icqaccount.cpp (revision 1198000)
@@ -236,7 +236,7 @@
myself()->setOnlineStatus( protocol()->statusManager()->connectingStatus() );
QString icqNumber = accountId();
kDebug(14153) << "Logging in as " << icqNumber;
- QString server = configGroup()->readEntry( "Server", QString::fromLatin1( "login.oscar.aol.com" ) );
+ QString server = configGroup()->readEntry( "Server", QString::fromLatin1( "login.icq.com" ) );
uint port = configGroup()->readEntry( "Port", 5190 );
//set up the settings for the account
Index: kopete/protocols/oscar/icq/ui/icqeditaccountwidget.cpp
--- kopete/protocols/oscar/icq/ui/icqeditaccountwidget.cpp (revision 1197798)
+++ kopete/protocols/oscar/icq/ui/icqeditaccountwidget.cpp (revision 1198000)
@@ -65,7 +65,7 @@
mProtocol->fillComboFromTable( mAccountSettings->encodingCombo, mProtocol->encodings() );
- //Setup the edtAccountId
+ //Setup the edtAccountId
QRegExp rx("[0-9]{9}");
QValidator* validator = new QRegExpValidator( rx, this );
mAccountSettings->edtAccountId->setValidator(validator);
@@ -80,9 +80,9 @@
mAccountSettings->mPasswordWidget->load(&mAccount->password());
mAccountSettings->chkAutoLogin->setChecked(mAccount->excludeConnect());
- QString serverEntry = mAccount->configGroup()->readEntry("Server", "login.oscar.aol.com");
+ QString serverEntry = mAccount->configGroup()->readEntry("Server", "login.icq.com");
int portEntry = mAccount->configGroup()->readEntry("Port", 5190);
- if ( serverEntry != "login.oscar.aol.com" || ( portEntry != 5190) )
+ if ( serverEntry != "login.icq.com" || ( portEntry != 5190) )
mAccountSettings->optionOverrideServer->setChecked( true );
mAccountSettings->edtServerAddress->setText( serverEntry );
@@ -254,7 +254,7 @@
}
else
{
- mAccount->setServerAddress("login.oscar.aol.com");
+ mAccount->setServerAddress("login.icq.com");
mAccount->setServerPort(5190);
}
Index: kopete/kopete/kconf_update/kopete-update_icq_server.upd
--- kopete/kopete/kconf_update/kopete-update_icq_server.upd (revision 0)
+++ kopete/kopete/kconf_update/kopete-update_icq_server.upd (revision 0)
@@ -0,0 +1,4 @@
+Id=kopete-update-icq-server/r1
+File=kopeterc
+Options=overwrite
+Script=kopete-update_icq_server.pl,perl
Index: kopete/kopete/kconf_update/kopete-update_icq_server.pl
--- kopete/kopete/kconf_update/kopete-update_icq_server.pl (revision 0)
+++ kopete/kopete/kconf_update/kopete-update_icq_server.pl (revision 0)
@@ -0,0 +1,20 @@
+#!/usr/bin/perl
+
+# AOL sold ICQ; change the default server to login.icq.com
+
+my $inICQ = 0;
+foreach (<>) {
+ $inICQ = 1 if (/^\[Account_ICQProtocol_.*$/);
+ if ($inICQ) {
+ if (/^Server\=(.*)/) {
+ my $oldServer = $1;
+ if ($oldServer =~ m/\.aol\.com$/) {
+ print "Server=login.icq.com\n";
+ $inICQ = 0;
+ next;
+ }
+ }
+ }
+
+ print $_;
+}
Index: kopete/kopete/kconf_update/CMakeLists.txt
--- kopete/kopete/kconf_update/CMakeLists.txt.orig 2008-01-05 00:59:03.000000000 +0100
+++ kopete/kopete/kconf_update/CMakeLists.txt 2010-11-17 14:32:45.000000000 +0100
@@ -1,6 +1,6 @@
if(NOT WIN32)
- install( PROGRAMS kopete-account-kconf_update.sh kopete-jabberpriorityaddition-kconf_update.sh kopete-pluginloader2.sh kopete-jabberproxytype-kconf_update.sh DESTINATION ${KCONF_UPDATE_INSTALL_DIR})
- install(FILES kopete-account-kconf_update.upd kopete-jabberproxytype-kconf_update.upd kopete-jabberpriorityaddition-kconf_update.upd kopete-pluginloader2.upd DESTINATION ${KCONF_UPDATE_INSTALL_DIR})
+ install( PROGRAMS kopete-account-kconf_update.sh kopete-jabberpriorityaddition-kconf_update.sh kopete-pluginloader2.sh kopete-jabberproxytype-kconf_update.sh kopete-update_icq_server.pl DESTINATION ${KCONF_UPDATE_INSTALL_DIR})
+ install(FILES kopete-account-kconf_update.upd kopete-jabberproxytype-kconf_update.upd kopete-jabberpriorityaddition-kconf_update.upd kopete-pluginloader2.upd kopete-update_icq_server.upd DESTINATION ${KCONF_UPDATE_INSTALL_DIR})
endif(NOT WIN32)