To make unblocking the main thread, the port existence check is moved to
the Watch() method. If the proxy application calls the rpc_port_proxy_connect()
function in the sub thread, the Aul::ExistPort() is called in the thread.
Change-Id: Ie82e0527c56981337c1b241c8d2b090696a1b0de
Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
return -1;
}
+ port_exist_ = Aul::ExistPort(real_appid_, port_name_,
+ rpc_port_get_target_uid());
+
SetConnTimer();
SetIdler();
return 0;
DestroyWeakPtr(proxy->idler_data_);
proxy->idler_data_ = nullptr;
- bool exist = Aul::ExistPort(proxy->real_appid_, proxy->port_name_,
- rpc_port_get_target_uid());
- if (exist) {
+ if (proxy->port_exist_) {
proxy->OnPortAppeared(proxy->real_appid_.c_str(),
proxy->port_name_.c_str(), -1, proxy.get());
} else {
gpointer conn_timer_data_ = nullptr;
gpointer idler_data_ = nullptr;
mutable std::recursive_mutex mutex_;
+ bool port_exist_ = false;
};
} // namespace internal