From ed7882fe69adc1bf02e354adf3ffdfb3b9d2d1d7 Mon Sep 17 00:00:00 2001 From: Daniel Gultsch Date: Thu, 1 Jun 2017 16:44:35 +0200 Subject: [PATCH] fix NPE when bookmark jid is null on creating suggestions --- .../eu/siacs/conversations/services/XmppConnectionService.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/eu/siacs/conversations/services/XmppConnectionService.java b/src/main/java/eu/siacs/conversations/services/XmppConnectionService.java index f4e6f456c..c4048a3bd 100644 --- a/src/main/java/eu/siacs/conversations/services/XmppConnectionService.java +++ b/src/main/java/eu/siacs/conversations/services/XmppConnectionService.java @@ -3506,7 +3506,8 @@ public class XmppConnectionService extends Service { mucServers.add(server); } for(Bookmark bookmark : account.getBookmarks()) { - final String s = bookmark.getJid().getDomainpart(); + final Jid jid = bookmark.getJid(); + final String s = jid == null ? null : jid.getDomainpart(); if (s != null && !mucServers.contains(s)) { mucServers.add(s); }