e_comp_wl_rsm: fix dereference null 25/231725/2
authorChangyeon Lee <cyeon.lee@samsung.com>
Fri, 24 Apr 2020 03:09:09 +0000 (12:09 +0900)
committerGwanglim Lee <gl77.lee@samsung.com>
Fri, 24 Apr 2020 03:38:20 +0000 (03:38 +0000)
Change-Id: Ifaacc271f54626a2ff869943f36335ee1a97e327

src/bin/e_comp_wl_rsm.c

index b3cab030816ce099d4ccd631cbc1aaa9f283b1b1..86d2ec62d1e33dee5c0150c37a49681b51b0f9df 100644 (file)
@@ -2346,7 +2346,7 @@ _remote_manager_cb_surface_create(struct wl_client *client,
 
         if (version >= TIZEN_REMOTE_SURFACE_CHANGED_BUFFER_SINCE_VERSION)
           {
-             if (ec->comp_data->sub.data)
+             if ((ec->comp_data) && (ec->comp_data->sub.data))
                {
                   ERR("Subsurface could not be source client");
                   goto fail;
@@ -2510,7 +2510,7 @@ _remote_manager_cb_surface_create_with_wl_surface(struct wl_client *client,
 
         if (version >= TIZEN_REMOTE_SURFACE_CHANGED_BUFFER_SINCE_VERSION)
           {
-             if (provider_ec->comp_data->sub.data)
+             if ((provider_ec->comp_data) && (provider_ec->comp_data->sub.data))
                {
                   ERR("Subsurface could not be source client");
                   goto fail;