diff options
author | Matthias Treydte <mt@waldheinz.de> | 2016-01-29 17:02:15 +0100 |
---|---|---|
committer | Bryce Harrington <bryce@osg.samsung.com> | 2016-03-08 23:23:26 -0800 |
commit | cd9424ef2a8face5d64b086bc55ab4e70e077beb (patch) | |
tree | 37f2581ac8a4d09c800b23d0bd38898b48671e26 /shared | |
parent | 38298ec0b45661d2969fc75c6cb47e0863755792 (diff) | |
download | weston-cd9424ef2a8face5d64b086bc55ab4e70e077beb.tar.gz |
platform: explicitly cast the return value of weston_platform_get_egl_proc_address
This allows the header to be consumed by C++ compilers, because C++ does
away with C's implicit cast from (void*).
Reviewed-by: Bryce Harrington <bryce@osg.samsung.com>
Diffstat (limited to 'shared')
-rw-r--r-- | shared/platform.h | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/shared/platform.h b/shared/platform.h index cf4ecc02..dd550081 100644 --- a/shared/platform.h +++ b/shared/platform.h @@ -75,8 +75,9 @@ weston_platform_get_egl_display(EGLenum platform, void *native_display, static PFNEGLGETPLATFORMDISPLAYEXTPROC get_platform_display = NULL; if (!get_platform_display) { - get_platform_display = weston_platform_get_egl_proc_address( - "eglGetPlatformDisplayEXT"); + get_platform_display = (PFNEGLGETPLATFORMDISPLAYEXTPROC) + weston_platform_get_egl_proc_address( + "eglGetPlatformDisplayEXT"); } if (get_platform_display) @@ -95,8 +96,9 @@ weston_platform_create_egl_surface(EGLDisplay dpy, EGLConfig config, create_platform_window = NULL; if (!create_platform_window) { - create_platform_window = weston_platform_get_egl_proc_address( - "eglCreatePlatformWindowSurfaceEXT"); + create_platform_window = (PFNEGLCREATEPLATFORMWINDOWSURFACEEXTPROC) + weston_platform_get_egl_proc_address( + "eglCreatePlatformWindowSurfaceEXT"); } if (create_platform_window) |