drm & wayland: Remove unnecessary close()

This commit is contained in:
Aleix Pol 2022-06-14 16:54:22 +02:00 committed by Aleix Pol Gonzalez
parent 1d5c803ce0
commit cd2567a838
2 changed files with 0 additions and 8 deletions

View file

@ -642,10 +642,6 @@ std::optional<DmaBufParams> DrmBackend::testCreateDmaBuf(const QSize &size, quin
}
auto ret = dmaBufParamsForBo(bo);
// We are just testing to know it works and check the modifier, no need to keep the fd
for (int i = 0, c = gbm_bo_get_plane_count(bo); i < c; ++i) {
close(gbm_bo_get_fd_for_plane(bo, i));
}
gbm_bo_destroy(bo);
return ret;
}

View file

@ -1036,10 +1036,6 @@ std::optional<DmaBufParams> WaylandBackend::testCreateDmaBuf(const QSize &size,
}
auto ret = dmaBufParamsForBo(bo);
// We are just testing to know it works and check the modifier, no need to keep the fd
for (int i = 0, c = gbm_bo_get_plane_count(bo); i < c; ++i) {
close(gbm_bo_get_fd_for_plane(bo, i));
}
gbm_bo_destroy(bo);
return ret;
}