summaryrefslogtreecommitdiff
path: root/src/gallium/auxiliary/draw/draw_pt_fetch.c
diff options
context:
space:
mode:
authorZack Rusin <zack@tungstengraphics.com>2008-04-23 14:07:53 -0400
committerZack Rusin <zack@tungstengraphics.com>2008-04-23 14:07:53 -0400
commit95f8f8863a80ce1e584160d4d085213a9bbaef12 (patch)
tree96adf740a47f7066f754b9624c1b376040f5d4ed /src/gallium/auxiliary/draw/draw_pt_fetch.c
parent5fcd84ab39318a371253b1a7285bc657fb82efed (diff)
Add translate cache to fetch_emit stage and add out of memory
checks to code creating the cache.
Diffstat (limited to 'src/gallium/auxiliary/draw/draw_pt_fetch.c')
-rw-r--r--src/gallium/auxiliary/draw/draw_pt_fetch.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/gallium/auxiliary/draw/draw_pt_fetch.c b/src/gallium/auxiliary/draw/draw_pt_fetch.c
index 8183c51676..cc61b113fd 100644
--- a/src/gallium/auxiliary/draw/draw_pt_fetch.c
+++ b/src/gallium/auxiliary/draw/draw_pt_fetch.c
@@ -158,6 +158,11 @@ struct pt_fetch *draw_pt_fetch_create( struct draw_context *draw )
fetch->draw = draw;
fetch->cache = translate_cache_create();
+ if (!fetch->cache) {
+ FREE(fetch);
+ return NULL;
+ }
+
return fetch;
}