From: Wonsik, Jung Date: Fri, 17 Nov 2017 09:02:50 +0000 (+0900) Subject: evas_tbm: fix incorrect return value of eng_output_setup() X-Git-Tag: submit/sandbox/upgrade/efl120/20180319.053334~949 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=6405caac7de7b8c02c423b910b0231b82a9b450d;p=platform%2Fupstream%2Fefl.git evas_tbm: fix incorrect return value of eng_output_setup() Fix incorrect return value of eng_output_setup() Change-Id: Ia8beb0d1d41c9d38cf0210baa3564f7464b7c249 --- diff --git a/src/modules/evas/engines/gl_tbm/evas_engine.c b/src/modules/evas/engines/gl_tbm/evas_engine.c index 630f586..1b21eda 100644 --- a/src/modules/evas/engines/gl_tbm/evas_engine.c +++ b/src/modules/evas/engines/gl_tbm/evas_engine.c @@ -942,7 +942,7 @@ _eng_swap_mode_get(void) return swap_mode; } -static int +static void * eng_output_setup(void *engine, void *info, unsigned int w, unsigned int h) { Render_Output_Swap_Mode swap_mode = MODE_FULL; @@ -1048,11 +1048,11 @@ eng_output_setup(void *engine, void *info, unsigned int w, unsigned int h) eng_window_use(eng_get_ob(re)); - return 1; + return re; ob_err: free(re); - return 0; + return NULL; } static int diff --git a/src/modules/evas/engines/software_tbm/evas_engine.c b/src/modules/evas/engines/software_tbm/evas_engine.c index acf5555..7919cc4 100644 --- a/src/modules/evas/engines/software_tbm/evas_engine.c +++ b/src/modules/evas/engines/software_tbm/evas_engine.c @@ -112,7 +112,7 @@ eng_output_info_setup(void *info) einfo->render_mode = EVAS_RENDER_MODE_BLOCKING; } -static int +static void * eng_output_setup(void *engine, void *info, unsigned int w, unsigned int h) { Evas_Engine_Info_Software_Tbm *einfo; @@ -121,7 +121,7 @@ eng_output_setup(void *engine, void *info, unsigned int w, unsigned int h) LOGFN(__FILE__, __LINE__, __FUNCTION__); /* try to cast to our engine info */ if (!(einfo = (Evas_Engine_Info_Software_Tbm *)info)) - return 0; + return NULL; /* if we have no engine data, assume we have not initialized yet */ evas_common_init(); @@ -137,11 +137,11 @@ eng_output_setup(void *engine, void *info, unsigned int w, unsigned int h) else goto err; - return 1; + return re; err: evas_common_shutdown(); - return 0; + return NULL; } static void