summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEmil Velikov <emil.l.velikov@gmail.com>2016-07-18 16:51:12 +0100
committerRob Herring <robh@kernel.org>2016-12-13 09:43:49 -0600
commit46983bb206e40b223a978ef756204b92db260d44 (patch)
tree00a62f2d33b186375d10b135547fadf31bac7972
parent128f82753be877d41ddcfbbdc22630f19121ad89 (diff)
downloadgbm_gralloc-46983bb206e40b223a978ef756204b92db260d44.tar.gz
gbm_gralloc-46983bb206e40b223a978ef756204b92db260d44.tar.xz
Open the device node with O_CLOEXEC
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> --- Not 100% sure it is supported on Android.
-rw-r--r--gralloc_gbm.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/gralloc_gbm.cpp b/gralloc_gbm.cpp
index 25cbf51..f162bf4 100644
--- a/gralloc_gbm.cpp
+++ b/gralloc_gbm.cpp
@@ -233,7 +233,7 @@ struct gbm_device *gbm_dev_create(void)
int fd;
property_get("gralloc.gbm.device", path, "/dev/dri/renderD128");
- fd = open(path, O_RDWR);
+ fd = open(path, O_RDWR | O_CLOEXEC);
if (fd < 0) {
ALOGE("failed to open %s", path);
return NULL;