https://git.reactos.org/?p=reactos.git;a=commitdiff;h=05b052fee2fb6d6a6db83e...
commit 05b052fee2fb6d6a6db83ec5855ad8971e100051 Author: Hermès Bélusca-Maïto hermes.belusca-maito@reactos.org AuthorDate: Mon Apr 22 18:29:43 2019 +0200 Commit: Hermès Bélusca-Maïto hermes.belusca-maito@reactos.org CommitDate: Mon Apr 22 18:29:43 2019 +0200
[OPENGL32] Fix the order of the specified callbacks for the DrvSetCallbackProcs() call.
References: - https://github.com/OpenSWR/openswr/blob/master/ogldriver/wgl.cpp - https://github.com/Igalia/mesa/blob/master/src/gallium/state_trackers/wgl/st... - "OpenGL Installable Client Driver, Version 1.101 -- Reference Guide" by Microsoft Corporation. --- dll/opengl/opengl32/icdload.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/dll/opengl/opengl32/icdload.c b/dll/opengl/opengl32/icdload.c index 0f4c65a782..fc86d86363 100644 --- a/dll/opengl/opengl32/icdload.c +++ b/dll/opengl/opengl32/icdload.c @@ -287,10 +287,11 @@ custom_end: DrvSetCallbackProcs = (void*)GetProcAddress(data->hModule, "DrvSetCallbackProcs"); if(DrvSetCallbackProcs) { - PROC callbacks[] = {(PROC)wglGetCurrentValue, + PROC callbacks[] = { (PROC)wglSetCurrentValue, + (PROC)wglGetCurrentValue, (PROC)wglGetDHGLRC}; - DrvSetCallbackProcs(3, callbacks); + DrvSetCallbackProcs(ARRAYSIZE(callbacks), callbacks); }
/* Get the DLL exports */