glx: use GLX_ALIAS for glXGetProcAddress
authorEmil Velikov <emil.velikov@collabora.com>
Mon, 5 Dec 2016 19:52:44 +0000 (19:52 +0000)
committerEmil Velikov <emil.l.velikov@gmail.com>
Wed, 18 Jan 2017 16:01:14 +0000 (16:01 +0000)
Use the macro, rather than open-coding it.

Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
src/glx/glxcmds.c

index 7266b58652e96e5d5b24f7de61ceda3b9f663d0c..6c7bbfd5d1c0cf893868725ee30cbe2bf1af20dd 100644 (file)
@@ -2663,19 +2663,10 @@ _GLX_PUBLIC void (*glXGetProcAddressARB(const GLubyte * procName)) (void)
  *
  * \sa glXGetProcAddressARB
  */
-_GLX_PUBLIC void (*glXGetProcAddress(const GLubyte * procName)) (void)
-# ifdef HAVE_FUNC_ATTRIBUTE_ALIAS
-# if defined(USE_MGL_NAMESPACE)
-   __attribute__ ((alias("mglXGetProcAddressARB")));
-# else
-   __attribute__ ((alias("glXGetProcAddressARB")));
-# endif
-#else
-{
-   return glXGetProcAddressARB(procName);
-}
-#endif /* HAVE_FUNC_ATTRIBUTE_ALIA */
-
+_GLX_PUBLIC
+GLX_ALIAS(__GLXextFuncPtr, glXGetProcAddress,
+          (const GLubyte * procName),
+          (procName), glXGetProcAddressARB)
 
 #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)
 /**