aboutsummaryrefslogtreecommitdiffstats
path: root/src/eu/siacs/conversations/xmpp/XmppConnection.java
diff options
context:
space:
mode:
authoriNPUTmice <daniel@gultsch.de>2014-08-14 09:59:41 +0200
committeriNPUTmice <daniel@gultsch.de>2014-08-14 09:59:41 +0200
commit510d8a2ae35ffe541ffd75b931e7d2e0e5e6b211 (patch)
tree8025cc89562e75556071dbc8ee87068bdd94e2f7 /src/eu/siacs/conversations/xmpp/XmppConnection.java
parentb2cc17c362c9994e2bf84e9233079744b6dc11ca (diff)
another rare npe fixed
Diffstat (limited to 'src/eu/siacs/conversations/xmpp/XmppConnection.java')
-rw-r--r--src/eu/siacs/conversations/xmpp/XmppConnection.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/eu/siacs/conversations/xmpp/XmppConnection.java b/src/eu/siacs/conversations/xmpp/XmppConnection.java
index b1f580d8..d8c9f4b9 100644
--- a/src/eu/siacs/conversations/xmpp/XmppConnection.java
+++ b/src/eu/siacs/conversations/xmpp/XmppConnection.java
@@ -416,8 +416,14 @@ public class XmppConnection implements Runnable {
NoSuchAlgorithmException {
tagReader.readTag(); // read tag close
+ if (!tagWriter.isActive()) {
+ throw new IOException();
+ }
tagWriter.setOutputStream(new ZLibOutputStream(tagWriter
.getOutputStream()));
+ if (tagReader.getInputStream() == null) {
+ throw new IOException();
+ }
tagReader
.setInputStream(new ZLibInputStream(tagReader.getInputStream()));