Change-Id: I6e92775ef19e58594b5792c5bfe24d4b4ab72856
return 0;
}
- bufmgr = bo->bufmgr;
-
- if (!TBM_BUFMGR_IS_VALID(bufmgr)) {
- TBM_LOG_E("error: bo->bufmgr is not valid.\n");
+ bufmgr = tbm_bufmgr_get();
+ if (bufmgr == NULL) {
+ TBM_LOG_E("error: bufmgr is NULL.\n");
return 0;
}
- if (LIST_IS_EMPTY(&bo->bufmgr->bo_list)) {
+ if (LIST_IS_EMPTY(&bufmgr->bo_list)) {
TBM_LOG_E("error: bo->bo->bufmgr->bo_list is EMPTY.\n");
return 0;
}
- LIST_FOR_EACH_ENTRY(old_data, &bo->bufmgr->bo_list, item_link) {
+ LIST_FOR_EACH_ENTRY(old_data, &bufmgr->bo_list, item_link) {
if (old_data == bo)
return 1;
}