elm_glview_render_func_set: workaround fix for rpi4 memory corruption. 19/237519/1
authorYoungGun Chun <jykeon@samsung.com>
Wed, 1 Jul 2020 04:57:19 +0000 (13:57 +0900)
committerYoungGun Chun <jykeon@samsung.com>
Wed, 1 Jul 2020 05:08:35 +0000 (14:08 +0900)
There is a something insane memory corruption when the callback is called in timer,

static void _cb_func(Evas_Object *obj)
{
   callback_counter++;
}

logically, it doesn't a problem, shouldn't be corrupted but it happens.

Change-Id: I26f06fb14281f86cf3199b3ef9abb1ca65362d8c

TC/elementary/glview/utc_elm_glview_render_func_set.c

index 1df2dbdd8ff65860212864bb58ab275a6eea0b92..95a02eccab12d987f38c61394fc97332f39a9ce6 100644 (file)
@@ -109,7 +109,6 @@ static void _cb_func(Evas_Object *obj)
 static Eina_Bool _timer_cb(void *data)
 {
    evas_object_show(glview);
-   elm_glview_changed_set(glview);
    elm_exit();
    return ECORE_CALLBACK_CANCEL;
 }
@@ -151,6 +150,7 @@ START_TEST(utc_elm_glview_render_func_set_p)
    evas_object_show(glview);
    evas_object_show(main_win);
    evas_object_show(box);
+   elm_glview_changed_set(glview);
    if (ecore_timer_add(0.2, _timer_cb, NULL) == NULL)
      {
         ck_abort_msg("[TEST_FAIL:: %s[%d] : Test has failed (timer cannot be created)..", __FILE__, __LINE__);