Fix issue detected by static analysis tool 13/313513/1
authorJihoon Kim <jihoon48.kim@samsung.com>
Thu, 27 Jun 2024 08:24:01 +0000 (17:24 +0900)
committerJihoon Kim <jihoon48.kim@samsung.com>
Thu, 27 Jun 2024 08:24:01 +0000 (17:24 +0900)
Change-Id: If97a35db764fabc7a3f5cbd8f25871c671047a20
Signed-off-by: Jihoon Kim <jihoon48.kim@samsung.com>
src/scim_thai_imengine.cpp

index a2e6e4bdd7c6354ec21deca4c35b3dfe84770fff..acb84a7ec83a9f44834fbeee0b3ddfd31c72886b 100644 (file)
@@ -82,7 +82,7 @@ ThaiInstance::_get_previous_cell ()
 
     if (get_surrounding_text (surrounding, cursor_index, -1, -1))
     {
-        thchar_t* tis_text = new thchar_t [cursor_index+1];
+        thchar_t* tis_text = new(std::nothrow) thchar_t [cursor_index+1];
         if (!tis_text)
             goto exit_point;