summaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
authorSiavash Eliasi <[email protected]>2014-01-30 11:38:55 +0330
committerMarek Olšák <[email protected]>2014-02-09 16:16:34 +0100
commit61bc014c966b3ef9743c82cb673988c05e06d9d0 (patch)
tree4dd62397d0f9ffa4b884c341000693042a05b9de /src/mesa
parent356aff3a5c08be055d6befff99a72f5551b3ac2d (diff)
mesa: Removed unnecessary check for NULL pointer when freeing memory
Note that it is OK to pass NULL pointers to this function since this commit: mesa: modified _mesa_align_free() to accept NULL pointer http://cgit.freedesktop.org/mesa/mesa/commit/?id=f0cc59d68a9f5231e8e2111393a1834858820735 Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/main/bufferobj.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/mesa/main/bufferobj.c b/src/mesa/main/bufferobj.c
index ca55ef9693f..d22e2c47d81 100644
--- a/src/mesa/main/bufferobj.c
+++ b/src/mesa/main/bufferobj.c
@@ -562,8 +562,7 @@ _mesa_buffer_data( struct gl_context *ctx, GLenum target, GLsizeiptrARB size,
(void) target;
- if (bufObj->Data)
- _mesa_align_free( bufObj->Data );
+ _mesa_align_free( bufObj->Data );
new_data = _mesa_align_malloc( size, ctx->Const.MinMapBufferAlignment );
if (new_data) {