diff --git a/daemon/src/managerimpl.cpp b/daemon/src/managerimpl.cpp index 9928812b352889ee92f596644f45a4e8f54f553c..a96ab6b284b44db436e1b2809e33b18666d266ad 100644 --- a/daemon/src/managerimpl.cpp +++ b/daemon/src/managerimpl.cpp @@ -390,7 +390,7 @@ bool ManagerImpl::answerCall(const std::string& call_id) } //THREAD=Main -void ManagerImpl::hangupCall(const std::string& callId) +bool ManagerImpl::hangupCall(const std::string& callId) { // store the current call id std::string currentCallId(getCurrentCallId()); @@ -408,7 +408,7 @@ void ManagerImpl::hangupCall(const std::string& callId) /* We often get here when the call was hungup before being created */ if (not isValidCall(callId) and not isIPToIP(callId)) { DEBUG("Could not hang up call %s, call not valid", callId.c_str()); - return; + return false; } // Disconnect streams @@ -433,6 +433,7 @@ void ManagerImpl::hangupCall(const std::string& callId) } } catch (const VoipLinkException &e) { ERROR("%s", e.what()); + return false; } } else { std::string accountId(getAccountFromCall(callId)); @@ -447,6 +448,7 @@ void ManagerImpl::hangupCall(const std::string& callId) } getMainBuffer().dumpInfo(); + return true; } bool ManagerImpl::hangupConference(const std::string& id) diff --git a/daemon/src/managerimpl.h b/daemon/src/managerimpl.h index 3c8e527d962f33c9ce4ad3d5f1068d5c9e8f8e7b..6eaf021b2c60330c58b86d80c553470593a63591 100644 --- a/daemon/src/managerimpl.h +++ b/daemon/src/managerimpl.h @@ -178,7 +178,7 @@ class ManagerImpl { * Hangup the call * @param id The call identifier */ - void hangupCall(const std::string& id); + bool hangupCall(const std::string& id); /**