Skip to content
This repository has been archived by the owner on Feb 11, 2021. It is now read-only.

Commit

Permalink
Browse files Browse the repository at this point in the history
Merged r3255:3256 from branches/SDL-1.2: stdlib problem with SDL_memc…
…py macro.
  • Loading branch information
icculus committed Jul 14, 2007
1 parent 639b8ec commit 1298366
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/stdlib/SDL_malloc.c
Expand Up @@ -610,7 +610,6 @@ DEFAULT_MMAP_THRESHOLD default: 256K
#endif /* MALLINFO_FIELD_TYPE */

#define memset SDL_memset
#define memcpy SDL_memcpy
#define malloc SDL_malloc
#define calloc SDL_calloc
#define realloc SDL_realloc
Expand Down Expand Up @@ -3913,7 +3912,7 @@ internal_realloc(mstate m, void *oldmem, size_t bytes)
void *newmem = internal_malloc(m, bytes);
if (newmem != 0) {
size_t oc = oldsize - overhead_for(oldp);
memcpy(newmem, oldmem, (oc < bytes) ? oc : bytes);
SDL_memcpy(newmem, oldmem, (oc < bytes) ? oc : bytes);
internal_free(m, oldmem);
}
return newmem;
Expand Down

0 comments on commit 1298366

Please sign in to comment.