aboutsummaryrefslogtreecommitdiff
path: root/render/egl.c
diff options
context:
space:
mode:
authorSimon Ser <contact@emersion.fr>2020-04-06 11:15:38 +0200
committerScott Anderson <scott@anderso.nz>2020-04-09 00:15:25 +0000
commit6787ff521bc55456947180f429e4a9eca70754c6 (patch)
treea621667cfeeaee2ce23c79ec210b74ffba1435b9 /render/egl.c
parent507d9bc19e05d3fd4378063ad87f4a74b3dfcfca (diff)
render/egl: make config attribs const
wlr_egl_init is not allowed to mutate these attribs.
Diffstat (limited to 'render/egl.c')
-rw-r--r--render/egl.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/render/egl.c b/render/egl.c
index de6d6b1b..b96a90f1 100644
--- a/render/egl.c
+++ b/render/egl.c
@@ -6,8 +6,8 @@
#include <wlr/util/log.h>
#include <wlr/util/region.h>
-static bool egl_get_config(EGLDisplay disp, EGLint *attribs, EGLConfig *out,
- EGLint visual_id) {
+static bool egl_get_config(EGLDisplay disp, const EGLint *attribs,
+ EGLConfig *out, EGLint visual_id) {
EGLint count = 0, matched = 0, ret;
ret = eglGetConfigs(disp, NULL, 0, &count);
@@ -132,7 +132,7 @@ out:
}
bool wlr_egl_init(struct wlr_egl *egl, EGLenum platform, void *remote_display,
- EGLint *config_attribs, EGLint visual_id) {
+ const EGLint *config_attribs, EGLint visual_id) {
// Check for EGL_EXT_platform_base before creating a display, because we
// actually use this extension to create displays. Check for EGL_KHR_debug
// before creating display to get EGL logs as soon as possible.