projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c66e38d
)
radeon: fix relocs even more
author
Dave Airlie
<airlied@linux.ie>
Thu, 22 Jan 2009 11:35:58 +0000
(21:35 +1000)
committer
Dave Airlie
<airlied@linux.ie>
Thu, 22 Jan 2009 11:35:58 +0000
(21:35 +1000)
src/mesa/drivers/dri/radeon/radeon_cs_legacy.c
patch
|
blob
|
history
diff --git
a/src/mesa/drivers/dri/radeon/radeon_cs_legacy.c
b/src/mesa/drivers/dri/radeon/radeon_cs_legacy.c
index ef59dd1f5c82e708cb3e192e80fa0e406d8f538b..f09031e83bb51dc58a93a1ab670131d7b7c28850 100644
(file)
--- a/
src/mesa/drivers/dri/radeon/radeon_cs_legacy.c
+++ b/
src/mesa/drivers/dri/radeon/radeon_cs_legacy.c
@@
-335,11
+335,15
@@
static int cs_emit(struct radeon_cs *cs)
return 0;
}
+static void inline cs_free_reloc(void *relocs_p)
+{
+ struct cs_reloc_legacy *relocs = relocs_p;
+ free(relocs->indices);
+}
+
static int cs_destroy(struct radeon_cs *cs)
{
- struct cs_reloc_legacy *relocs;
- relocs = cs->relocs;
- free(relocs->indices);
+ cs_free_reloc(cs->relocs);
free(cs->relocs);
free(cs->packets);
free(cs);
@@
-348,6
+352,7
@@
static int cs_destroy(struct radeon_cs *cs)
static int cs_erase(struct radeon_cs *cs)
{
+ cs_free_reloc(cs->relocs);
free(cs->relocs);
cs->relocs_total_size = 0;
cs->relocs = NULL;