rpc_port_proxy_destroy() calls DisconnectPort() method to disconnect main port.
Change-Id: Ia86611a4a6442805f94af335a699a105ad285f5e
Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
return RPC_PORT_ERROR_NONE;
}
-// LCOV_EXCL_START
int Proxy::ConnectSync(std::string appid, std::string port_name,
IEventListener* ev) {
if (ev == nullptr)
return RPC_PORT_ERROR_NONE;
}
-// LCOV_EXCL_STOP
+
+void Proxy::DisconnectPort() {
+ main_port_.reset();
+}
void Proxy::SetRealAppId(const std::string& alias_appid) {
if (!real_appid_.empty())
int Connect(std::string appid, std::string port_name, IEventListener* ev);
int ConnectSync(std::string appid, std::string port_name, IEventListener* ev);
+ void DisconnectPort();
std::shared_ptr<Port> GetPort() const {
return main_port_;
return RPC_PORT_ERROR_INVALID_PARAMETER;
auto p = static_cast<::ProxyExt*>(h);
+ _W("rpc_port_proxy_destroy(%p)", p);
p->SetDestroying(true);
+ p->DisconnectPort();
g_idle_add_full(G_PRIORITY_HIGH,
[](gpointer data) -> gboolean {