removed outdated tls error

This commit is contained in:
iNPUTmice 2014-07-24 01:37:38 +02:00
parent 3b786c34f2
commit deab99c997
3 changed files with 2 additions and 11 deletions

View file

@ -40,7 +40,6 @@ public class Account extends AbstractEntity{
public static final int STATUS_ONLINE = 1; public static final int STATUS_ONLINE = 1;
public static final int STATUS_NO_INTERNET = 2; public static final int STATUS_NO_INTERNET = 2;
public static final int STATUS_UNAUTHORIZED = 3; public static final int STATUS_UNAUTHORIZED = 3;
public static final int STATUS_TLS_ERROR = 4;
public static final int STATUS_SERVER_NOT_FOUND = 5; public static final int STATUS_SERVER_NOT_FOUND = 5;
public static final int STATUS_SERVER_REQUIRES_TLS = 6; public static final int STATUS_SERVER_REQUIRES_TLS = 6;

View file

@ -121,11 +121,6 @@ public class ManageAccountActivity extends XmppActivity {
.setText(getString(R.string.account_status_requires_tls)); .setText(getString(R.string.account_status_requires_tls));
statusView.setTextColor(0xFFe92727); statusView.setTextColor(0xFFe92727);
break; break;
case Account.STATUS_TLS_ERROR:
statusView
.setText(getString(R.string.account_status_error));
statusView.setTextColor(0xFFe92727);
break;
case Account.STATUS_REGISTRATION_FAILED: case Account.STATUS_REGISTRATION_FAILED:
statusView statusView
.setText(getString(R.string.account_status_regis_fail)); .setText(getString(R.string.account_status_regis_fail));
@ -163,8 +158,7 @@ public class ManageAccountActivity extends XmppActivity {
int position, long arg3) { int position, long arg3) {
if (!isActionMode) { if (!isActionMode) {
Account account = accountList.get(position); Account account = accountList.get(position);
if ((account.getStatus() == Account.STATUS_OFFLINE) if (account.getStatus() == Account.STATUS_OFFLINE) {
|| (account.getStatus() == Account.STATUS_TLS_ERROR)) {
activity.xmppConnectionService.reconnectAccount( activity.xmppConnectionService.reconnectAccount(
accountList.get(position), true); accountList.get(position), true);
} else if (account.getStatus() == Account.STATUS_ONLINE) { } else if (account.getStatus() == Account.STATUS_ONLINE) {

View file

@ -192,9 +192,7 @@ public class XmppConnection implements Runnable {
} }
return; return;
} catch (IOException e) { } catch (IOException e) {
if (account.getStatus() != Account.STATUS_TLS_ERROR) { this.changeStatus(Account.STATUS_OFFLINE);
this.changeStatus(Account.STATUS_OFFLINE);
}
if (wakeLock.isHeld()) { if (wakeLock.isHeld()) {
try { wakeLock.release();} catch (RuntimeException re) {} try { wakeLock.release();} catch (RuntimeException re) {}
} }