tpl_wayland_egl_thread: Added an null exception checking. 56/193556/1
authorJoonbum Ko <joonbum.ko@samsung.com>
Tue, 20 Nov 2018 05:45:23 +0000 (14:45 +0900)
committerJoonbum Ko <joonbum.ko@samsung.com>
Tue, 20 Nov 2018 05:45:23 +0000 (14:45 +0900)
Change-Id: I7fd92cc21c22b9c6a4b2f751829542b1f9402b10
Signed-off-by: Joonbum Ko <joonbum.ko@samsung.com>
src/tpl_wayland_egl_thread.c

index aaa73d0..87c54a7 100644 (file)
@@ -2728,6 +2728,11 @@ twe_surface_get_swapchain_buffers(twe_surface_h twe_surface,
                return TPL_ERROR_INVALID_PARAMETER;
        }
 
+       if (!buffer_count) {
+               TPL_ERR("Invalid parameter. buffer_count is NULL.");
+               return TPL_ERROR_INVALID_PARAMETER;
+       }
+
        if (!surfaces) {
                *buffer_count = tbm_surface_queue_get_size(surf_source->tbm_queue);
                return TPL_ERROR_NONE;