Merged r3255:3256 from branches/SDL-1.2: stdlib problem with SDL_memcpy macro.
authorRyan C. Gordon <icculus@icculus.org>
Sat, 14 Jul 2007 06:46:33 +0000
changeset 219455e987d8e1b5
parent 2193 e857f02e709e
child 2195 46e373b27d6d
Merged r3255:3256 from branches/SDL-1.2: stdlib problem with SDL_memcpy macro.
src/stdlib/SDL_malloc.c
     1.1 --- a/src/stdlib/SDL_malloc.c	Sat Jul 14 00:07:37 2007 +0000
     1.2 +++ b/src/stdlib/SDL_malloc.c	Sat Jul 14 06:46:33 2007 +0000
     1.3 @@ -610,7 +610,6 @@
     1.4  #endif /* MALLINFO_FIELD_TYPE */
     1.5  
     1.6  #define memset	SDL_memset
     1.7 -#define memcpy	SDL_memcpy
     1.8  #define malloc	SDL_malloc
     1.9  #define calloc	SDL_calloc
    1.10  #define realloc	SDL_realloc
    1.11 @@ -3913,7 +3912,7 @@
    1.12              void *newmem = internal_malloc(m, bytes);
    1.13              if (newmem != 0) {
    1.14                  size_t oc = oldsize - overhead_for(oldp);
    1.15 -                memcpy(newmem, oldmem, (oc < bytes) ? oc : bytes);
    1.16 +                SDL_memcpy(newmem, oldmem, (oc < bytes) ? oc : bytes);
    1.17                  internal_free(m, oldmem);
    1.18              }
    1.19              return newmem;