Mesa (master): llvmpipe: Ensure transfers are mapped.

Jose Fonseca jrfonseca at kemper.freedesktop.org
Fri Dec 4 13:27:32 PST 2009


Module: Mesa
Branch: master
Commit: a312e76468435fc1eb7ec5fe0a98601a7fdfec53
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=a312e76468435fc1eb7ec5fe0a98601a7fdfec53

Author: José Fonseca <jfonseca at vmware.com>
Date:   Fri Dec  4 21:16:14 2009 +0000

llvmpipe: Ensure transfers are mapped.

This shouldn't happen but it does by some misterious reason. Fail the
assertion but at least do not segfault on release builds.

---

 src/gallium/drivers/llvmpipe/lp_tile_cache.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/src/gallium/drivers/llvmpipe/lp_tile_cache.c b/src/gallium/drivers/llvmpipe/lp_tile_cache.c
index 50891c4..e83210f 100644
--- a/src/gallium/drivers/llvmpipe/lp_tile_cache.c
+++ b/src/gallium/drivers/llvmpipe/lp_tile_cache.c
@@ -290,6 +290,10 @@ lp_get_cached_tile(struct llvmpipe_tile_cache *tc,
    
    assert(tc->surface);
    assert(tc->transfer);
+   assert(tc->transfer_map);
+
+   if(!tc->transfer_map)
+      lp_tile_cache_map_transfers(tc);
 
    switch(tile->status) {
    case LP_TILE_STATUS_CLEAR:



More information about the mesa-commit mailing list