Module: Mesa Branch: master Commit: fa62cf7450595b3d99259b5a212df301ca711d4b URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=fa62cf7450595b3d99259b5a212df301ca711d4b
Author: Jerome Glisse <jgli...@redhat.com> Date: Tue Dec 21 10:49:53 2010 -0500 r600g: avoid segfault Candidates 7.10 Signed-off-by: Jerome Glisse <jgli...@redhat.com> --- src/gallium/drivers/r600/evergreen_state.c | 2 +- src/gallium/drivers/r600/r600_state.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gallium/drivers/r600/evergreen_state.c b/src/gallium/drivers/r600/evergreen_state.c index af19beb..8a69a10 100644 --- a/src/gallium/drivers/r600/evergreen_state.c +++ b/src/gallium/drivers/r600/evergreen_state.c @@ -1334,7 +1334,7 @@ void evergreen_vertex_buffer_update(struct r600_pipe_context *rctx) rbuffer = (struct r600_resource*)vertex_buffer->buffer; offset = 0; } - if (vertex_buffer == NULL) + if (vertex_buffer == NULL || rbuffer == NULL) continue; offset += vertex_buffer->buffer_offset + r600_bo_offset(rbuffer->bo); diff --git a/src/gallium/drivers/r600/r600_state.c b/src/gallium/drivers/r600/r600_state.c index 0d76afd..9b099df 100644 --- a/src/gallium/drivers/r600/r600_state.c +++ b/src/gallium/drivers/r600/r600_state.c @@ -174,7 +174,7 @@ void r600_vertex_buffer_update(struct r600_pipe_context *rctx) rbuffer = (struct r600_resource*)vertex_buffer->buffer; offset = 0; } - if (vertex_buffer == NULL) + if (vertex_buffer == NULL || rbuffer == NULL) continue; offset += vertex_buffer->buffer_offset + r600_bo_offset(rbuffer->bo); _______________________________________________ mesa-commit mailing list mesa-commit@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-commit