Mesa (i965g-restart): i965g: init pointer to null, avoid segfault
Keith Whitwell
keithw at kemper.freedesktop.org
Wed Nov 4 15:45:26 PST 2009
Module: Mesa
Branch: i965g-restart
Commit: 518171a887437e4d3fc2c8cea871862afb63c11c
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=518171a887437e4d3fc2c8cea871862afb63c11c
Author: Keith Whitwell <keithw at vmware.com>
Date: Wed Nov 4 23:27:30 2009 +0000
i965g: init pointer to null, avoid segfault
---
src/gallium/drivers/i965/brw_draw_upload.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/src/gallium/drivers/i965/brw_draw_upload.c b/src/gallium/drivers/i965/brw_draw_upload.c
index f0b7c74..6e12e8f 100644
--- a/src/gallium/drivers/i965/brw_draw_upload.c
+++ b/src/gallium/drivers/i965/brw_draw_upload.c
@@ -202,7 +202,7 @@ static int brw_prepare_vertices(struct brw_context *brw)
for (i = 0; i < brw->curr.num_vertex_buffers; i++) {
struct pipe_vertex_buffer *vb = &brw->curr.vertex_buffer[i];
struct brw_winsys_buffer *bo;
- struct pipe_buffer *upload_buf;
+ struct pipe_buffer *upload_buf = NULL;
unsigned offset;
if (BRW_DEBUG & DEBUG_VERTS)
More information about the mesa-commit
mailing list