aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/eu
diff options
context:
space:
mode:
authorDaniel Gultsch <daniel@gultsch.de>2016-11-01 10:27:01 +0100
committerDaniel Gultsch <daniel@gultsch.de>2016-11-01 10:27:01 +0100
commit20ddba2aa9b173054b1c7922b41892cc42bc31ef (patch)
tree85ce460894e79e732eeddbe52eaeb6b2403cb48a /src/main/java/eu
parent07a71d312a8eaaa9b43686905c804dec99c34cef (diff)
fixed npe when jingle partner is using unknown candidate
Diffstat (limited to 'src/main/java/eu')
-rw-r--r--src/main/java/eu/siacs/conversations/xmpp/jingle/JingleConnection.java4
1 files changed, 4 insertions, 0 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 0d6d8c0c..5461b9c6 100644
--- a/src/main/java/eu/siacs/conversations/xmpp/jingle/JingleConnection.java
+++ b/src/main/java/eu/siacs/conversations/xmpp/jingle/JingleConnection.java
@@ -620,6 +620,10 @@ public class JingleConnection implements Transferable {
if (cid != null) {
Log.d(Config.LOGTAG, "candidate used by counterpart:" + cid);
JingleCandidate candidate = getCandidate(cid);
+ if (candidate == null) {
+ Log.d(Config.LOGTAG,"could not find candidate with cid="+cid);
+ return false;
+ }
candidate.flagAsUsedByCounterpart();
this.receivedCandidate = true;
if ((mJingleStatus == JINGLE_STATUS_ACCEPTED)