To allow delete this, app com uses std::iterator. After this patch is
applied, the caller process can call aul_app_com_leave() while calling
the app_com_cb() callback function.
Change-Id: I0e6202810d99af556197c35b9c06303185e25482
Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
std::string endpoint(val);
std::lock_guard<std::recursive_mutex> lock(mutex_);
- for (auto& conn : conns_) {
+ auto iter = conns_.begin();
+ while (iter != conns_.end()) {
+ auto& conn = *iter;
+ iter++;
if (conn->GetEndpoint() == endpoint)
conn->Invoke(*result, b);
}