From 2d42646893fce35fd952e02e94cc8ec0818870b3 Mon Sep 17 00:00:00 2001 From: Daniel Gultsch Date: Thu, 16 Nov 2017 12:49:15 +0100 Subject: [PATCH] JingleConnection: fixed rare npe when canceling jingle --- .../eu/siacs/conversations/xmpp/jingle/JingleConnection.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/main/java/eu/siacs/conversations/xmpp/jingle/JingleConnection.java b/src/main/java/eu/siacs/conversations/xmpp/jingle/JingleConnection.java index c91c7ac61..c153cbc92 100644 --- a/src/main/java/eu/siacs/conversations/xmpp/jingle/JingleConnection.java +++ b/src/main/java/eu/siacs/conversations/xmpp/jingle/JingleConnection.java @@ -100,7 +100,7 @@ public class JingleConnection implements Transferable { private byte[] expectedHash = new byte[0]; private boolean responding() { - return responder.equals(account.getJid()); + return responder != null && responder.equals(account.getJid()); } private boolean initiating() { @@ -914,8 +914,7 @@ public class JingleConnection implements Transferable { } this.mJingleConnectionManager.updateConversationUi(true); } else { - this.mXmppConnectionService.markMessage(this.message, - Message.STATUS_SEND_FAILED); + this.mXmppConnectionService.markMessage(this.message, Message.STATUS_SEND_FAILED); this.message.setTransferable(null); } }