From: Kazumasa Mitsunari Date: Sun, 10 Jun 2018 14:48:46 +0000 (+0900) Subject: Change function according to 1476fb X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=commitdiff_plain;h=bdf5562f360402f810278ccbb3fdbab6b464d1c3;hp=1476fb12566dd8d7de9c598bb0ac78e454f52d11;p=apps%2Fagl-service-windowmanager.git Change function according to 1476fb Change-Id: I372040dded0fd38139b3d8b2ebd0d8988d12e8f1 Signed-off-by: Kazumasa Mitsunari --- diff --git a/src/app.cpp b/src/app.cpp index db00dea..d11ec8a 100644 --- a/src/app.cpp +++ b/src/app.cpp @@ -572,8 +572,15 @@ WMError App::do_transition(unsigned req_num) * Check Policy */ // get current trigger - auto trigger = g_app_list.getRequest(req_num); + bool found; bool is_activate = true; + auto trigger = g_app_list.getRequest(req_num, &found); + if(!found) + { + WMError err = WMError::NO_ENTRY; + HMI_SEQ_ERROR(req_num, errorDescription(err)); + return err; + } /* get new status from Policy Manager @@ -606,8 +613,14 @@ WMError App::do_transition(unsigned req_num) // layer manager task bool sync_draw_happen = false; - for (const auto &y : g_app_list.getActions(req_num)) + for (const auto &y : g_app_list.getActions(req_num, &found)) { + if (!found) + { + WMError err = WMError::NO_ENTRY; + HMI_SEQ_ERROR(req_num, "%s : Action is not set", errorDescription(err)); + return err; + } /* do_task(y); */ @@ -1006,7 +1019,15 @@ void App::lm_enddraw(const char *drawing_name) void App::do_enddraw(unsigned req_num) { // get actions - auto actions = g_app_list.getActions(req_num); + bool found; + auto actions = g_app_list.getActions(req_num, &found); + if (!found) + { + WMError err = WMError::NO_ENTRY; + HMI_SEQ_ERROR(req_num, errorDescription(err)); + return; + } + HMI_SEQ_INFO(req_num, "do endDraw"); for (const auto &act : actions)