aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/eu/siacs/conversations/entities
diff options
context:
space:
mode:
authorDaniel Gultsch <daniel@gultsch.de>2015-07-03 21:32:46 +0200
committerDaniel Gultsch <daniel@gultsch.de>2015-07-03 22:35:52 +0200
commit097bdf1a3ea4a1821b18eeffebaff4bd4d395817 (patch)
tree5d9fa542d2dd7fdbb7c450e58b063680bed472c2 /src/main/java/eu/siacs/conversations/entities
parent96fe75fe9f7e143268e6306fd799eceaad85c48d (diff)
avoid very rare npe
Diffstat (limited to '')
-rw-r--r--src/main/java/eu/siacs/conversations/entities/Roster.java3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/main/java/eu/siacs/conversations/entities/Roster.java b/src/main/java/eu/siacs/conversations/entities/Roster.java
index d6777ef63..628a31d1c 100644
--- a/src/main/java/eu/siacs/conversations/entities/Roster.java
+++ b/src/main/java/eu/siacs/conversations/entities/Roster.java
@@ -74,6 +74,9 @@ public class Roster {
}
public void initContact(final Contact contact) {
+ if (contact == null) {
+ return;
+ }
contact.setAccount(account);
contact.setOption(Contact.Options.IN_ROSTER);
synchronized (this.contacts) {