From a3e9addd8010a91173b34d3c2f38b9c7c28aae98 Mon Sep 17 00:00:00 2001 From: Alcaro Date: Mon, 14 Nov 2016 17:23:11 +0100 Subject: [PATCH] Clean this one up a little --- gfx/drivers_context/wgl_ctx.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/gfx/drivers_context/wgl_ctx.cpp b/gfx/drivers_context/wgl_ctx.cpp index d8b5f3967a..88b5eb87de 100644 --- a/gfx/drivers_context/wgl_ctx.cpp +++ b/gfx/drivers_context/wgl_ctx.cpp @@ -125,9 +125,7 @@ static void create_gl_context(HWND hwnd, bool *quit) hwr = video_driver_get_hw_context(); debug = hwr->debug_context; -#ifdef _WIN32 dll_handle = dylib_load("OpenGL32.dll"); -#endif g_hdc = GetDC(hwnd); setup_pixel_format(g_hdc); @@ -591,9 +589,9 @@ static bool gfx_ctx_wgl_has_windowed(void *data) static gfx_ctx_proc_t gfx_ctx_wgl_get_proc_address(const char *symbol) { #if defined(HAVE_OPENGL) || defined(HAVE_VULKAN) - void *func = (void *)wglGetProcAddress(symbol); + gfx_ctx_proc_t func = (gfx_ctx_proc_t)wglGetProcAddress(symbol); if (func) - return (gfx_ctx_proc_t)wglGetProcAddress(symbol); + return func; #endif return (gfx_ctx_proc_t)GetProcAddress((HINSTANCE)dll_handle, symbol); }