aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/eu/siacs/conversations/ui
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/eu/siacs/conversations/ui')
-rw-r--r--src/main/java/eu/siacs/conversations/ui/ConversationActivity.java9
-rw-r--r--src/main/java/eu/siacs/conversations/ui/XmppActivity.java6
2 files changed, 9 insertions, 6 deletions
diff --git a/src/main/java/eu/siacs/conversations/ui/ConversationActivity.java b/src/main/java/eu/siacs/conversations/ui/ConversationActivity.java
index c6ec63df..8cb8a3aa 100644
--- a/src/main/java/eu/siacs/conversations/ui/ConversationActivity.java
+++ b/src/main/java/eu/siacs/conversations/ui/ConversationActivity.java
@@ -896,12 +896,11 @@ public class ConversationActivity extends XmppActivity implements
public void run() {
updateConversationList();
if (conversationList.size() == 0) {
- startActivity(new Intent(getApplicationContext(),
- StartConversationActivity.class));
- finish();
- } else {
- ConversationActivity.this.mConversationFragment.updateMessages();
+ startActivity(new Intent(getApplicationContext(),
+ StartConversationActivity.class));
+ finish();
}
+ ConversationActivity.this.mConversationFragment.updateMessages();
}
});
}
diff --git a/src/main/java/eu/siacs/conversations/ui/XmppActivity.java b/src/main/java/eu/siacs/conversations/ui/XmppActivity.java
index 78d7956a..2dafbd26 100644
--- a/src/main/java/eu/siacs/conversations/ui/XmppActivity.java
+++ b/src/main/java/eu/siacs/conversations/ui/XmppActivity.java
@@ -105,7 +105,11 @@ public abstract class XmppActivity extends Activity {
XmppConnectionBinder binder = (XmppConnectionBinder) service;
xmppConnectionService = binder.getService();
xmppConnectionServiceBound = true;
- onBackendConnected();
+ if (!isFinishing() && !isDestroyed()) {
+ onBackendConnected();
+ } else {
+ Log.d(Config.LOGTAG,"omitting call to onBackendConnected()");
+ }
}
@Override