diff options
author | Ton Roosendaal <ton@blender.org> | 2005-04-17 22:00:33 +0400 |
---|---|---|
committer | Ton Roosendaal <ton@blender.org> | 2005-04-17 22:00:33 +0400 |
commit | d34acbfe44b552f6416619568ea1ea851ef3ebd7 (patch) | |
tree | 7a10356c8db5898eaffc120c7874a0276d02e8bb /source/blender/src/swapbuffers.c | |
parent | 425f2956043fb9da71bfa34086d923cda4b0e9c2 (diff) |
Replaced a bunch of malloc() calls with proper MEM_mallocN()
(and free() and calloc() of course)
Remainder malloc() calls need to be there for realloc().
Diffstat (limited to 'source/blender/src/swapbuffers.c')
-rw-r--r-- | source/blender/src/swapbuffers.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/src/swapbuffers.c b/source/blender/src/swapbuffers.c index 8e106f52fa2..cad8d86e677 100644 --- a/source/blender/src/swapbuffers.c +++ b/source/blender/src/swapbuffers.c @@ -69,7 +69,7 @@ static void copy_back_to_front(void) winlay_get_winsize(&winx, &winy); if (actually_swap) { - data= malloc(4*winx*winy); + data= MEM_mallocN(4*winx*winy, "swap"); glReadPixels(0, 0, winx, winy, GL_RGBA, GL_UNSIGNED_BYTE, data); } @@ -85,7 +85,7 @@ static void copy_back_to_front(void) glRasterPos2f(-0.5,-0.5); glDrawPixels(winx, winy, GL_RGBA, GL_UNSIGNED_BYTE, data); glFlush(); - free(data); + MEM_freeN(data); } } #endif |