aboutsummaryrefslogtreecommitdiffstats
path: root/src/eu/siacs
diff options
context:
space:
mode:
Diffstat (limited to 'src/eu/siacs')
-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()));