diff options
author | Seung-Woo Kim <sw0312.kim@samsung.com> | 2018-03-20 14:45:32 +0900 |
---|---|---|
committer | Seung-Woo Kim <sw0312.kim@samsung.com> | 2019-04-25 17:59:27 +0900 |
commit | 1a9c8245439acece921dcb87cc9b460725b182bc (patch) | |
tree | a307063524240be48f37abad8d3586d5b781abe2 | |
parent | 9149007913ed243fe3e17909881285e9049478cc (diff) | |
download | libdrm-1a9c8245439acece921dcb87cc9b460725b182bc.tar.gz libdrm-1a9c8245439acece921dcb87cc9b460725b182bc.tar.bz2 libdrm-1a9c8245439acece921dcb87cc9b460725b182bc.zip |
nexell: fix to check return of drmIoctl()
Fix to check return value of drmIoctl().
Change-Id: I456184820278ee38ff1a7e5bba283acb8c2ea99f
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
-rw-r--r-- | nexell/nexell_drm.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/nexell/nexell_drm.c b/nexell/nexell_drm.c index 38b904ac..867c8804 100644 --- a/nexell/nexell_drm.c +++ b/nexell/nexell_drm.c @@ -58,9 +58,12 @@ int nx_alloc_gem(int drm_fd, int size, int flags) void nx_free_gem(int drm_fd, int gem) { struct drm_gem_close arg = {0, }; + int ret; arg.handle = gem; - drmIoctl(drm_fd, DRM_IOCTL_GEM_CLOSE, &arg); + ret = drmIoctl(drm_fd, DRM_IOCTL_GEM_CLOSE, &arg); + if (ret) + perror("DRM_IOCTL_GEM_CLOSE failed\n"); } /** |