Mesa (master): iris: replace all dup() with os_dupfd_cloexec()

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Thu Jun 18 02:25:51 UTC 2020


Module: Mesa
Branch: master
Commit: e0e9c2486d6cb1330dfab5a40d35bdc267c9da66
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=e0e9c2486d6cb1330dfab5a40d35bdc267c9da66

Author: Eric Engestrom <eric at engestrom.ch>
Date:   Fri Jun  5 10:54:51 2020 +0200

iris: replace all dup() with os_dupfd_cloexec()

Signed-off-by: Eric Engestrom <eric at engestrom.ch>
Reviewed-by: Kristian H. Kristensen <hoegsberg at google.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin at intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5369>

---

 src/gallium/drivers/iris/iris_bufmgr.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/gallium/drivers/iris/iris_bufmgr.c b/src/gallium/drivers/iris/iris_bufmgr.c
index 5529d3767da..e6b5c9763b5 100644
--- a/src/gallium/drivers/iris/iris_bufmgr.c
+++ b/src/gallium/drivers/iris/iris_bufmgr.c
@@ -1801,7 +1801,7 @@ iris_bufmgr_create(struct gen_device_info *devinfo, int fd, bool bo_reuse)
     * Don't do this! Ensure that each library/bufmgr has its own device
     * fd so that its namespace does not clash with another.
     */
-   bufmgr->fd = dup(fd);
+   bufmgr->fd = os_dupfd_cloexec(fd);
 
    p_atomic_set(&bufmgr->refcount, 1);
 



More information about the mesa-commit mailing list