[Piglit] [PATCH] arb_internalformat_query2: add APIENTRY qualifier to fix MSVC build

Brian Paul brianp at vmware.com
Wed Jul 13 15:01:18 UTC 2016


The GetInternalformat() function pointer type must be declared with
APIENTRY because it points to either the glGetInternalformativ() or
glGetInternalformati64v() GL entrypoint.  Fixes a runtime crash.
---
 tests/spec/arb_internalformat_query2/common.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/spec/arb_internalformat_query2/common.c b/tests/spec/arb_internalformat_query2/common.c
index 1d60abb..3454ed0 100644
--- a/tests/spec/arb_internalformat_query2/common.c
+++ b/tests/spec/arb_internalformat_query2/common.c
@@ -26,7 +26,7 @@
 
 /* Generic callback type, doing a cast of params to void*, to avoid
  * having two paths (32 and 64) for each check */
-typedef void (*GetInternalformat)(GLenum target, GLenum internalformat,
+typedef void (APIENTRY *GetInternalformat)(GLenum target, GLenum internalformat,
                                   GLenum pname, GLsizei bufsize,
                                   void *params);
 
-- 
1.9.1



More information about the Piglit mailing list