aboutsummaryrefslogtreecommitdiff
path: root/libdino/src/service/registration.vala
diff options
context:
space:
mode:
authorfiaxh <git@lightrise.org>2019-11-27 18:46:29 +0100
committerfiaxh <git@lightrise.org>2019-11-27 20:01:48 +0100
commit1985fe1d7b94bd1eff80bb3da14bbc52e5585163 (patch)
treef908b8bafdfc8166a6c60159ee7eb6a9a4389078 /libdino/src/service/registration.vala
parentc4325473fba84db6d48bf2ca9e79214fef1cca2f (diff)
downloaddino-1985fe1d7b94bd1eff80bb3da14bbc52e5585163.tar.gz
dino-1985fe1d7b94bd1eff80bb3da14bbc52e5585163.zip
Don't continue reading after stream was disconnected, make disconnecting async
fixes #636
Diffstat (limited to 'libdino/src/service/registration.vala')
-rw-r--r--libdino/src/service/registration.vala6
1 files changed, 3 insertions, 3 deletions
diff --git a/libdino/src/service/registration.vala b/libdino/src/service/registration.vala
index 20ea6063..19eebb05 100644
--- a/libdino/src/service/registration.vala
+++ b/libdino/src/service/registration.vala
@@ -37,7 +37,7 @@ public class Register : StreamInteractionModule, Object{
if (connected_account.equals(account)) {
ret = error.source;
}
- stream_interactor.disconnect_account(account);
+ stream_interactor.disconnect_account.begin(account);
Idle.add((owned)callback);
});
@@ -91,7 +91,7 @@ public class Register : StreamInteractionModule, Object{
yield;
try {
- stream.disconnect();
+ yield stream.disconnect();
} catch (Error e) {}
return ret;
}
@@ -130,7 +130,7 @@ public class Register : StreamInteractionModule, Object{
form = yield stream.get_module(Xep.InBandRegistration.Module.IDENTITY).get_from_server(stream, jid);
}
try {
- stream.disconnect();
+ yield stream.disconnect();
} catch (Error e) {}
return form;