This patch cleans up tdm_buffer_unref_backend().
The 'buffer' is not changed in buf_info->release_funcs list loop,
so does not need to call ref & unref inside.
Change-Id: I924bc4abde130be37ee800534e161beee56ae09a
Signed-off-by: YoungJun Cho <yj44.cho@samsung.com>
// if (!tdm_thread_in_display_thread(syscall(SYS_gettid)))
// TDM_NEVER_GET_HERE();
- LIST_FOR_EACH_ENTRY_SAFE(func_info, next, &buf_info->release_funcs, link) {
- tbm_surface_internal_ref(buffer);
+ tbm_surface_internal_ref(buffer);
+ LIST_FOR_EACH_ENTRY_SAFE(func_info, next, &buf_info->release_funcs, link)
func_info->release_func(buffer, func_info->user_data);
- tbm_surface_internal_unref(buffer);
- }
+ tbm_surface_internal_unref(buffer);
tbm_surface_internal_unref(buffer);
}