Fix bugs about app info management for updated apps 33/317933/1
authorHwankyu Jhun <h.jhun@samsung.com>
Fri, 10 Jan 2025 03:59:40 +0000 (12:59 +0900)
committerHwankyu Jhun <h.jhun@samsung.com>
Fri, 10 Jan 2025 03:59:40 +0000 (12:59 +0900)
There is a bug about executing an application whil that is updating.
It causes by calling aul_status_update_v2(). When the application calls
the function, amd changes the status of the app info to 'norestart'.
This patch add an exception handling about the 'blocking' status.
If the status is 'blocking', amd does not set the 'norestart' status to
the app info.

Change-Id: I1c2d4d9da394d6afa2a8a5dc5672411a726edfa8
Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
src/lib/amd_app_status.cc

index 893308155853aa09dbc74de2ff98d1c9e935a5af..187814dc9cc3d524410aa28e594a60dec066fbce 100644 (file)
@@ -1218,7 +1218,11 @@ static int DispatchAppStatusUpdateV2(request_h request) {
     if (app_info == nullptr) {
       ret = -1;
     } else {
-      app_info->SetStatus("norestart");
+      if (app_info->GetStatus() == "blocking")
+        _W("Blocking status. appid(%s)", app_info->GetAppId().c_str());
+      else
+        app_info->SetStatus("norestart");
+
       ret = 0;
     }
   } else {