summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swiften/Roster')
-rw-r--r--Swiften/Roster/XMPPRosterController.cpp5
-rw-r--r--Swiften/Roster/XMPPRosterController.h1
2 files changed, 6 insertions, 0 deletions
diff --git a/Swiften/Roster/XMPPRosterController.cpp b/Swiften/Roster/XMPPRosterController.cpp
index 7743ec8..feaa7d4 100644
--- a/Swiften/Roster/XMPPRosterController.cpp
+++ b/Swiften/Roster/XMPPRosterController.cpp
@@ -25,6 +25,11 @@ namespace Swift {
*/
XMPPRosterController::XMPPRosterController(IQRouter* iqRouter, XMPPRoster* xmppRoster) : iqRouter_(iqRouter), rosterPushResponder_(iqRouter), xmppRoster_(xmppRoster) {
rosterPushResponder_.onRosterReceived.connect(boost::bind(&XMPPRosterController::handleRosterReceived, this, _1));
+ rosterPushResponder_.start();
+}
+
+XMPPRosterController::~XMPPRosterController() {
+ rosterPushResponder_.stop();
}
void XMPPRosterController::requestRoster() {
diff --git a/Swiften/Roster/XMPPRosterController.h b/Swiften/Roster/XMPPRosterController.h
index 3ef7795..22a63ad 100644
--- a/Swiften/Roster/XMPPRosterController.h
+++ b/Swiften/Roster/XMPPRosterController.h
@@ -22,6 +22,7 @@ namespace Swift {
class XMPPRosterController {
public:
XMPPRosterController(IQRouter *iqRouter, XMPPRoster* xmppRoster);
+ ~XMPPRosterController();
void requestRoster();