From b8aa377d883c316f544274dd24db9f079fb8f02a Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Fri, 10 Jul 2009 02:18:42 +0200 Subject: NetworkUserBackend: Detach() aufrufen --- src/Common/Backends/NetworkUserBackend.cpp | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) (limited to 'src/Common') diff --git a/src/Common/Backends/NetworkUserBackend.cpp b/src/Common/Backends/NetworkUserBackend.cpp index 20deba6..1e06a78 100644 --- a/src/Common/Backends/NetworkUserBackend.cpp +++ b/src/Common/Backends/NetworkUserBackend.cpp @@ -84,6 +84,8 @@ void NetworkUserBackend::UserUpdateRequest::sendRequest() { } boost::shared_ptr > NetworkUserBackend::getUserList(boost::posix_time::ptime *timestamp) throw(Core::Exception) { + application->getThreadManager()->detach(); + boost::shared_ptr request(new SimpleUserRequest(application, "ListUsers", timestamp)); application->getRequestManager()->sendRequest(connection, request); @@ -119,6 +121,8 @@ boost::shared_ptr > NetworkUserBackend:: } boost::shared_ptr NetworkUserBackend::getUserInfo(unsigned long uid, boost::posix_time::ptime *timestamp) throw(Core::Exception) { + application->getThreadManager()->detach(); + boost::shared_ptr request(new IdUserRequest(application, "GetUserInfo", "uid", uid, timestamp)); application->getRequestManager()->sendRequest(connection, request); request->wait(); @@ -149,6 +153,8 @@ boost::shared_ptr NetworkUserBackend::getUserInfo(unsigned long } boost::shared_ptr NetworkUserBackend::getUserInfoByName(const std::string &name, boost::posix_time::ptime *timestamp) throw(Core::Exception) { + application->getThreadManager()->detach(); + boost::shared_ptr request(new NameUserRequest(application, "GetUserInfo", name, timestamp)); application->getRequestManager()->sendRequest(connection, request); request->wait(); @@ -179,6 +185,8 @@ boost::shared_ptr NetworkUserBackend::getUserInfoByName(const st } boost::shared_ptr > NetworkUserBackend::getUserGroupList(unsigned long uid, boost::posix_time::ptime *timestamp) throw(Core::Exception) { + application->getThreadManager()->detach(); + boost::shared_ptr request(new IdUserRequest(application, "ListUserGroups", "uid", uid, timestamp)); application->getRequestManager()->sendRequest(connection, request); request->wait(); @@ -209,6 +217,8 @@ boost::shared_ptr > NetworkUserBackend::getUserGro } boost::shared_ptr > NetworkUserBackend::getGroupList(boost::posix_time::ptime *timestamp) throw(Core::Exception) { + application->getThreadManager()->detach(); + boost::shared_ptr request(new SimpleUserRequest(application, "ListGroups", timestamp)); application->getRequestManager()->sendRequest(connection, request); request->wait(); @@ -240,6 +250,8 @@ boost::shared_ptr > NetworkUserBackend: } boost::shared_ptr NetworkUserBackend::getGroupInfo(unsigned long gid, boost::posix_time::ptime *timestamp) throw(Core::Exception) { + application->getThreadManager()->detach(); + boost::shared_ptr request(new IdUserRequest(application, "GetGroupInfo", "gid", gid, timestamp)); application->getRequestManager()->sendRequest(connection, request); request->wait(); @@ -264,6 +276,8 @@ boost::shared_ptr NetworkUserBackend::getGroupInfo(unsigned lon } boost::shared_ptr NetworkUserBackend::getGroupInfoByName(const std::string &name, boost::posix_time::ptime *timestamp) throw(Core::Exception) { + application->getThreadManager()->detach(); + boost::shared_ptr request(new NameUserRequest(application, "GetGroupInfo", name, timestamp)); application->getRequestManager()->sendRequest(connection, request); request->wait(); @@ -288,6 +302,8 @@ boost::shared_ptr NetworkUserBackend::getGroupInfoByName(const } boost::shared_ptr > NetworkUserBackend::getGroupUserList(unsigned long gid, boost::posix_time::ptime *timestamp) throw(Core::Exception) { + application->getThreadManager()->detach(); + boost::shared_ptr request(new IdUserRequest(application, "ListGroupUsers", "gid", gid, timestamp)); application->getRequestManager()->sendRequest(connection, request); request->wait(); @@ -318,6 +334,8 @@ boost::shared_ptr > NetworkUserBackend::getGroupUs } boost::shared_ptr > NetworkUserBackend::getFullUserGroupList(boost::posix_time::ptime *timestamp) throw(Core::Exception) { + application->getThreadManager()->detach(); + boost::shared_ptr request(new SimpleUserRequest(application, "GetFullUserGroupList", timestamp)); application->getRequestManager()->sendRequest(connection, request); request->wait(); @@ -353,6 +371,8 @@ boost::shared_ptr > NetworkUse void NetworkUserBackend::addUser(const UserInfo &userInfo) throw(Core::Exception) { + application->getThreadManager()->detach(); + boost::shared_ptr request(new UserAddRequest(application, userInfo)); application->getRequestManager()->sendRequest(connection, request); request->wait(); @@ -363,6 +383,8 @@ void NetworkUserBackend::addUser(const UserInfo &userInfo) throw(Core::Exception } void NetworkUserBackend::updateUser(unsigned long uid, const Common::UserInfo &userInfo) throw(Core::Exception) { + application->getThreadManager()->detach(); + boost::shared_ptr request(new UserUpdateRequest(application, uid, userInfo)); application->getRequestManager()->sendRequest(connection, request); request->wait(); @@ -373,6 +395,8 @@ void NetworkUserBackend::updateUser(unsigned long uid, const Common::UserInfo &u } void NetworkUserBackend::deleteUser(unsigned long uid) throw(Core::Exception) { + application->getThreadManager()->detach(); + boost::shared_ptr request(new IdUserRequest(application, "DeleteUser", "uid", uid)); application->getRequestManager()->sendRequest(connection, request); request->wait(); -- cgit v1.2.3