Replace the exception case in tizen backend. 48/324748/2
authorWonsik Jung <sidein@samsung.com>
Sat, 24 May 2025 23:56:28 +0000 (08:56 +0900)
committerWonsik Jung <sidein@samsung.com>
Tue, 27 May 2025 05:50:07 +0000 (14:50 +0900)
Replace the excepption case in tizen backend when display server does not work.
When display server does not work, then ecore_wl2_display_connect() does not work and crash occurs in application size.
To handle the failure case where the display server does not work in the Tizen backend, you can modify the ecore_wl2_display_connect() function to avoid crashing the application.
Specifically, replace the exit() call with a more graceful error handling mechanism.

Change-Id: Ice83d181fe468bc0b9bdcca48f2fcc6496d855f1

dali/internal/window-system/tizen-wayland/ecore-wl2/window-base-ecore-wl2.cpp

index 0d94b239b1df29fac897154e61e45cadf608a401..33c46b30d661ac44c8a4a29886ca2276a55e5662 100644 (file)
@@ -3362,7 +3362,8 @@ void WindowBaseEcoreWl2::CreateInternalWindow(PositionSize positionSize)
   Ecore_Wl2_Display* display = ecore_wl2_display_connect(NULL);
   if(!display)
   {
-    DALI_ASSERT_ALWAYS(0 && "Failed to get display");
+    DALI_LOG_ERROR("Failed to get display, then application will be exit");
+    exit(1);
   }
 
   {