From 52e64f816cd5842a5c1b513d7df6cbfe3daed732 Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Sat, 22 Feb 2025 12:21:10 -0800 Subject: [PATCH] Use SDL C runtime functions in OpenVR driver Fixes link errors when building with -DSDL_LIBC=OFF --- src/video/openvr/SDL_openvrvideo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/video/openvr/SDL_openvrvideo.c b/src/video/openvr/SDL_openvrvideo.c index a565260ad5..6387c37439 100644 --- a/src/video/openvr/SDL_openvrvideo.c +++ b/src/video/openvr/SDL_openvrvideo.c @@ -911,7 +911,7 @@ static SDL_GLContext OPENVR_GL_CreateContext(SDL_VideoDevice *_this, SDL_Window OPENVR_SetupFrame(_this, window); - SDL_GLContext result = malloc(sizeof(struct SDL_GLContextState)); + SDL_GLContext result = SDL_malloc(sizeof(struct SDL_GLContextState)); if (!result) { return NULL; }