diff options
author | Michel Dänzer <michel@tungstengraphics.com> | 2007-03-12 19:08:28 +0100 |
---|---|---|
committer | Michel Dänzer <michel@tungstengraphics.com> | 2007-03-12 19:08:28 +0100 |
commit | 708d836e6b785764692c485e6cdf42f2b50fcf86 (patch) | |
tree | 8824084700e465c551c564d4a3812ee7dc4cbc65 /src/mesa | |
parent | 17fb7821d7cdc0ed211eaef013ee7798619a61d3 (diff) |
i915tex: Don't crash when intel_fb->color_rb[i] is NULL.
This can be the case on some systems when running glxinfo.
Diffstat (limited to 'src/mesa')
-rw-r--r-- | src/mesa/drivers/dri/i915tex/intel_buffers.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i915tex/intel_buffers.c b/src/mesa/drivers/dri/i915tex/intel_buffers.c index 45fd2fa8de..62ff54b007 100644 --- a/src/mesa/drivers/dri/i915tex/intel_buffers.c +++ b/src/mesa/drivers/dri/i915tex/intel_buffers.c @@ -327,6 +327,9 @@ intelWindowMoved(struct intel_context *intel) } for (i = 0; i < intel_fb->pf_num_pages; i++) { + if (!intel_fb->color_rb[i]) + continue; + vbl.request.sequence = intel_fb->color_rb[i]->vbl_pending; drmWaitVBlank(intel->driFd, &vbl); } @@ -336,7 +339,8 @@ intelWindowMoved(struct intel_context *intel) intel_fb->vbl_waited = intel_fb->vbl_seq; for (i = 0; i < intel_fb->pf_num_pages; i++) { - intel_fb->color_rb[i]->vbl_pending = intel_fb->vbl_waited; + if (intel_fb->color_rb[i]) + intel_fb->color_rb[i]->vbl_pending = intel_fb->vbl_waited; } } } else { |