dumb: Don't save fd when tbm_bo_import_fd() is colled. 54/61354/1 accepted/tizen/common/20160307.154833 accepted/tizen/ivi/20160308.021619 accepted/tizen/mobile/20160308.021428 accepted/tizen/tv/20160308.021503 accepted/tizen/wearable/20160308.021539 submit/tizen/20160307.110800
authorRoman Marchenko <r.marchenko@samsung.com>
Wed, 17 Feb 2016 13:35:58 +0000 (15:35 +0200)
committerSooChan Lim <sc1.lim@samsung.com>
Mon, 7 Mar 2016 10:42:46 +0000 (19:42 +0900)
The user of libtbm have to control state of "fd" by himself. So libtbm shouldn't save fd which received by tbm_bo_import_fd()

Change-Id: Iec7fa7227d7f0f77a3d508095ee13d905fd58f2d
Signed-off-by: Roman Marchenko <r.marchenko@samsung.com>
src/tbm_bufmgr_dumb.c

index d1d1d7b..e4d80ab 100644 (file)
@@ -673,7 +673,7 @@ tbm_dumb_bo_import_fd (tbm_bo bo, tbm_fd key)
 
     bo_dumb->fd = bufmgr_dumb->fd;
     bo_dumb->gem = gem;
-    bo_dumb->dmabuf = key;
+    bo_dumb->dmabuf = 0;
     bo_dumb->size = real_size;
     bo_dumb->flags_dumb = 0;
     bo_dumb->flags_tbm = _get_tbm_flag_from_dumb (bo_dumb->flags_dumb);