return PKGMGR_R_EINVAL;
}
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
for (int i = 0; i < n_pkgs; i++)
pkgs.push_back(pkg_paths[i]);
- const auto& receiver = con->GetSignalReceiver();
int ret = proxy->InstallPkgs(uid, pkgs, con->GetArgv(),
con->GenerateRequestId(), req_key);
if (ret != PKGMGR_R_OK)
con->SetTepArgs();
}
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
- const auto& receiver = con->GetSignalReceiver();
std::string req_key;
int ret = proxy->Install(uid, pkg_type ? pkg_type : "", pkg_path, con->GetArgv(),
con->GenerateRequestId(), req_key);
return PKGMGR_R_EINVAL;
}
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
- const auto& receiver = con->GetSignalReceiver();
std::string req_key;
int ret = proxy->Reinstall(uid, pkgid, req_key);
if (ret != PKGMGR_R_OK)
return PKGMGR_R_EINVAL;
}
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
for (int i = 0; i < n_pkgs; i++)
pkgs.push_back(pkgids[i]);
- const auto& receiver = con->GetSignalReceiver();
int ret = proxy->UninstallPkgs(uid, pkgs, req_key);
if (ret != PKGMGR_R_OK)
return ret;
return PKGMGR_R_EINVAL;
}
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
- const auto& receiver = con->GetSignalReceiver();
std::string req_key;
int ret = proxy->Uninstall(uid, pkgid, req_key);
if (ret != PKGMGR_R_OK)
return PKGMGR_R_EINVAL;
}
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
pkgs.push_back(pkg_paths[i]);
}
- const auto& receiver = con->GetSignalReceiver();
int ret = proxy->MountInstallPkgs(uid, pkgs, con->GenerateRequestId(),
req_key);
if (ret != PKGMGR_R_OK)
con->SetTepArgs();
}
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
- const auto& receiver = con->GetSignalReceiver();
std::string req_key;
int ret = proxy->MountInstall(uid, pkg_type ? pkg_type : "", pkg_path,
con->GetArgv(), con->GenerateRequestId(), req_key);
return PKGMGR_R_EINVAL;
}
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
- const auto& receiver = con->GetSignalReceiver();
std::string req_key;
int ret = proxy->Move(uid, pkgid, move_type, req_key);
if (ret != PKGMGR_R_OK)
return PKGMGR_R_EINVAL;
}
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
vec.push_back(pkgids[i]);
}
- const auto& receiver = con->GetSignalReceiver();
int ret = proxy->EnablePkgs(uid, std::move(vec), req_key);
if (ret != PKGMGR_R_OK)
return ret;
return PKGMGR_R_EINVAL;
}
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
for (int i = 0; i < n_pkgs; i++) {
vec.push_back(pkgids[i]);
}
- const auto& receiver = con->GetSignalReceiver();
int ret = proxy->DisablePkgs(uid, std::move(vec), req_key);
if (ret != PKGMGR_R_OK)
return ret;
}
auto* con = static_cast<Connector*>(pc);
+ if (con->GetPcType() != PC_REQUEST) {
+ _E("client type is not PC_REQUEST");
+ return PKGMGR_R_EINVAL;
+ }
+
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
- const auto& receiver = con->GetSignalReceiver();
std::string req_key;
int ret = proxy->EnableApp(uid, appid, req_key);
if (ret != PKGMGR_R_OK)
return PKGMGR_R_EINVAL;
}
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
vec.push_back(appids[i]);
}
- const auto& receiver = con->GetSignalReceiver();
int ret = proxy->EnableApps(uid, std::move(vec), req_key);
if (ret != PKGMGR_R_OK)
return ret;
}
auto* con = static_cast<Connector*>(pc);
+ if (con->GetPcType() != PC_REQUEST) {
+ _E("client type is not PC_REQUEST");
+ return PKGMGR_R_EINVAL;
+ }
+
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
- const auto& receiver = con->GetSignalReceiver();
std::string req_key;
int ret = proxy->EnableGlobalAppForUid(uid, appid, req_key);
if (ret != PKGMGR_R_OK)
}
auto* con = static_cast<Connector*>(pc);
+ if (con->GetPcType() != PC_REQUEST) {
+ _E("client type is not PC_REQUEST");
+ return PKGMGR_R_EINVAL;
+ }
+
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
- const auto& receiver = con->GetSignalReceiver();
std::string req_key;
int ret = proxy->DisableApp(uid, appid, req_key);
if (ret != PKGMGR_R_OK)
return PKGMGR_R_EINVAL;
}
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
vec.push_back(appids[i]);
}
- const auto& receiver = con->GetSignalReceiver();
int ret = proxy->DisableApps(uid, std::move(vec), req_key);
if (ret != PKGMGR_R_OK)
return ret;
}
auto* con = static_cast<Connector*>(pc);
+ if (con->GetPcType() != PC_REQUEST) {
+ _E("client type is not PC_REQUEST");
+ return PKGMGR_R_EINVAL;
+ }
+
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
- const auto& receiver = con->GetSignalReceiver();
std::string req_key;
int ret = proxy->DisableGlobalAppForUid(uid, appid, req_key);
if (ret != PKGMGR_R_OK)
return PKGMGR_R_EINVAL;
}
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetInfoProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
- const auto& receiver = con->GetSignalReceiver();
std::string req_key;
int ret = proxy->GetSize(uid, pkgid, get_type, req_key);
if (ret != PKGMGR_R_OK)
return PKGMGR_R_EINVAL;
}
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetInfoProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
- const auto& receiver = con->GetSignalReceiver();
std::string req_key;
int ret = proxy->GetSize(uid, pkgid, get_type, req_key);
if (ret != PKGMGR_R_OK)
}
auto* con = static_cast<Connector*>(pc);
+ if (con->GetPcType() != PC_REQUEST) {
+ _E("client type is not PC_REQUEST");
+ return PKGMGR_R_EINVAL;
+ }
+
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
- const auto& receiver = con->GetSignalReceiver();
std::string req_key;
int ret = proxy->ResCopy(con->GetResCopyPath(), req_key);
}
auto* con = static_cast<Connector*>(pc);
+ if (con->GetPcType() != PC_REQUEST) {
+ _E("client type is not PC_REQUEST");
+ return PKGMGR_R_EINVAL;
+ }
+
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
- const auto& receiver = con->GetSignalReceiver();
std::string req_key;
int ret = proxy->ResCreateDir(con->GetResCreateDir(), req_key);
}
auto* con = static_cast<Connector*>(pc);
+ if (con->GetPcType() != PC_REQUEST) {
+ _E("client type is not PC_REQUEST");
+ return PKGMGR_R_EINVAL;
+ }
+
+ const auto& receiver = con->GetSignalReceiver();
auto* proxy = con->GetAdminProxy();
if (proxy == nullptr)
return PKGMGR_R_EIO;
- const auto& receiver = con->GetSignalReceiver();
std::string req_key;
int ret = proxy->ResRemove(con->GetResRemovePath(), req_key);