Change-Id: I8e5d4ae7a35097e0e52227d62e0ba8ca74c9a6a7
Signed-off-by: YoungJun Cho <yj44.cho@samsung.com>
#define LOG_TAG "SC_PROVIDER"
-static int __init_count;
-static struct tizen_remote_surface_manager *__rsm;
+static int __init_count = 0;
+static struct tizen_remote_surface_manager *__rsm = NULL;
struct screen_connector_provider_s {
struct wl_surface *surface;
Ecore_Wl_Global *global;
Eina_Inlist *globals;
- if (__init_count > 0)
+ if (__init_count > 0) {
+ __init_count++;
return 0;
+ }
ecore_wl_init(NULL);
EXPORT_API int screen_connector_provider_fini(void)
{
- if (__init_count > 1)
+ if (__init_count > 1) {
+ __init_count--;
return 0;
+ }
if (__rsm)
tizen_remote_surface_manager_destroy(__rsm);