aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mapi
diff options
context:
space:
mode:
Diffstat (limited to 'mesalib/src/mapi')
-rw-r--r--mesalib/src/mapi/glapi/gen/glX_proto_send.py6
-rw-r--r--mesalib/src/mapi/glapi/gen/gl_x86-64_asm.py2
-rw-r--r--mesalib/src/mapi/glapi/gen/gl_x86_asm.py2
-rw-r--r--mesalib/src/mapi/glapi/glapi_dispatch.c2
-rw-r--r--mesalib/src/mapi/glapi/glapi_getproc.c2
-rw-r--r--mesalib/src/mapi/mapi/u_current.c2
-rw-r--r--mesalib/src/mapi/mapi/u_thread.h4
7 files changed, 10 insertions, 10 deletions
diff --git a/mesalib/src/mapi/glapi/gen/glX_proto_send.py b/mesalib/src/mapi/glapi/gen/glX_proto_send.py
index c53359240..d42f661ea 100644
--- a/mesalib/src/mapi/glapi/gen/glX_proto_send.py
+++ b/mesalib/src/mapi/glapi/gen/glX_proto_send.py
@@ -239,7 +239,7 @@ __glXReadPixelReply( Display *dpy, struct glx_context * gc, unsigned max_dim,
size = reply.length * 4;
if (size != 0) {
- void * buf = Xmalloc( size );
+ void * buf = malloc( size );
if ( buf == NULL ) {
_XEatData(dpy, size);
@@ -255,7 +255,7 @@ __glXReadPixelReply( Display *dpy, struct glx_context * gc, unsigned max_dim,
__glEmptyImage(gc, 3, width, height, depth, format, type,
buf, dest);
- Xfree(buf);
+ free(buf);
}
}
}
@@ -970,7 +970,7 @@ struct _glapi_table * __glXNewIndirectAPI( void )
int o;
entries = _glapi_get_dispatch_table_size();
- table = (_glapi_proc *) Xmalloc(entries * sizeof(_glapi_proc));
+ table = malloc(entries * sizeof(_glapi_proc));
/* first, set all entries to point to no-op functions */
for (i = 0; i < entries; i++) {
diff --git a/mesalib/src/mapi/glapi/gen/gl_x86-64_asm.py b/mesalib/src/mapi/glapi/gen/gl_x86-64_asm.py
index ef759bf7b..3ef5e08a9 100644
--- a/mesalib/src/mapi/glapi/gen/gl_x86-64_asm.py
+++ b/mesalib/src/mapi/glapi/gen/gl_x86-64_asm.py
@@ -138,7 +138,7 @@ class PrintGenericStubs(gl_XML.gl_print_base):
print '# define GL_PREFIX(n) GLNAME(CONCAT(gl,n))'
print '# endif'
print ''
- print '#if defined(PTHREADS) || defined(WIN32)'
+ print '#if defined(PTHREADS) || defined(_WIN32)'
print '# define THREADS'
print '#endif'
print ''
diff --git a/mesalib/src/mapi/glapi/gen/gl_x86_asm.py b/mesalib/src/mapi/glapi/gen/gl_x86_asm.py
index b43b65dd8..095edcdc0 100644
--- a/mesalib/src/mapi/glapi/gen/gl_x86_asm.py
+++ b/mesalib/src/mapi/glapi/gen/gl_x86_asm.py
@@ -78,7 +78,7 @@ class PrintGenericStubs(gl_XML.gl_print_base):
print '#define GLOBL_FN(x) GLOBL x'
print '#endif'
print ''
- print '#if defined(PTHREADS) || defined(WIN32)'
+ print '#if defined(PTHREADS) || defined(_WIN32)'
print '# define THREADS'
print '#endif'
print ''
diff --git a/mesalib/src/mapi/glapi/glapi_dispatch.c b/mesalib/src/mapi/glapi/glapi_dispatch.c
index 989f4a3fc..be65ebedd 100644
--- a/mesalib/src/mapi/glapi/glapi_dispatch.c
+++ b/mesalib/src/mapi/glapi/glapi_dispatch.c
@@ -43,7 +43,7 @@
#if !(defined(USE_X86_ASM) || defined(USE_X86_64_ASM) || defined(USE_SPARC_ASM))
-#if defined(WIN32)
+#if defined(_WIN32)
#define KEYWORD1 GLAPI
#else
#define KEYWORD1 PUBLIC
diff --git a/mesalib/src/mapi/glapi/glapi_getproc.c b/mesalib/src/mapi/glapi/glapi_getproc.c
index 0a6ff7795..f976d5808 100644
--- a/mesalib/src/mapi/glapi/glapi_getproc.c
+++ b/mesalib/src/mapi/glapi/glapi_getproc.c
@@ -244,7 +244,7 @@ static char *
str_dup(const char *str)
{
char *copy;
- copy = (char*) malloc(strlen(str) + 1);
+ copy = malloc(strlen(str) + 1);
if (!copy)
return NULL;
strcpy(copy, str);
diff --git a/mesalib/src/mapi/mapi/u_current.c b/mesalib/src/mapi/mapi/u_current.c
index 21a07abba..d902375f8 100644
--- a/mesalib/src/mapi/mapi/u_current.c
+++ b/mesalib/src/mapi/mapi/u_current.c
@@ -125,7 +125,7 @@ static int ThreadSafe;
void
u_current_destroy(void)
{
-#if defined(THREADS) && defined(WIN32)
+#if defined(THREADS) && defined(_WIN32)
u_tsd_destroy(&u_current_table_tsd);
u_tsd_destroy(&u_current_user_tsd);
#endif
diff --git a/mesalib/src/mapi/mapi/u_thread.h b/mesalib/src/mapi/mapi/u_thread.h
index ffe17b207..e53f872c9 100644
--- a/mesalib/src/mapi/mapi/u_thread.h
+++ b/mesalib/src/mapi/mapi/u_thread.h
@@ -153,7 +153,7 @@ u_tsd_set(struct u_tsd *tsd, void *ptr)
* IMPORTANT: Link with multithreaded runtime library when THREADS are
* used!
*/
-#ifdef WIN32
+#ifdef _WIN32
struct u_tsd {
DWORD key;
@@ -225,7 +225,7 @@ u_tsd_set(struct u_tsd *tsd, void *ptr)
}
}
-#endif /* WIN32 */
+#endif /* _WIN32 */
/*