bundle_del(b, AUL_SVC_K_RES_VAL);
auto* cb_info = static_cast<CbInfo*>(data);
+ if (cb_info == nullptr) {
+ _E("Invalid parameter");
+ return;
+ }
+
if (cb_info->res_fn_) {
cb_info->res_fn_(b, cb_info->request_code_,
static_cast<aul_svc_result_val>(res), cb_info->user_data_);
+ cb_info->res_fn_ = nullptr;
}
if (cb_info->err_cb_ != nullptr)
error = AulErrorConvert(error);
auto* cb_info = static_cast<CbInfo*>(data);
+ if (cb_info == nullptr) {
+ _E("Invalid parameter");
+ return;
+ }
+
if (cb_info->err_cb_) {
cb_info->err_cb_(cb_info->request_code_, error, cb_info->user_data_);
cb_info->err_cb_ = nullptr;
CbInfo* cb_info = nullptr;
if (cbfunc)
cb_info = new (std::nothrow) CbInfo(request_code, cbfunc, nullptr, data);
+ if (cb_info == nullptr)
+ LOGE("Out of memory");
std::tuple<aul_svc_res_fn, void*> param { cbfunc, data };
int ret = ::SendLaunchRequest<::SendLaunchRequestCb, ::CbInfo*>(
CbInfo* cb_info = new (std::nothrow) CbInfo(request_code, cbfunc, err_cb,
user_data);
+ if (cb_info == nullptr)
+ _E("Out of memory");
+
int ret = ::SendLaunchRequest<::SendLaunchRequestCb, ::CbInfo*>(
[](const std::string& appid, bundle* request, uid_t uid,
CbInfo* info) -> int {
auto* cb_info = new (std::nothrow) CbInfo(request_code, nullptr, err_cb,
user_data);
+ if (cb_info == nullptr)
+ _E("Out of memory");
+
int ret = ::SendLaunchRequest<::SendLaunchRequestCb, ::CbInfo*>(
[](const std::string& appid, bundle* request, uid_t uid,
CbInfo* info) -> int {