summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Swiften/Client/ClientSession.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/Swiften/Client/ClientSession.cpp b/Swiften/Client/ClientSession.cpp
index 791ee75..fd001a1 100644
--- a/Swiften/Client/ClientSession.cpp
+++ b/Swiften/Client/ClientSession.cpp
@@ -420,7 +420,9 @@ void ClientSession::finishSession(Error::Type error) {
void ClientSession::finishSession(boost::shared_ptr<Swift::Error> error) {
state = Finishing;
- error_ = error;
+ if (!error_) {
+ error_ = error;
+ }
assert(stream->isOpen());
if (stanzaAckResponder_) {
stanzaAckResponder_->handleAckRequestReceived();