summaryrefslogtreecommitdiff
path: root/render
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2013-05-15 19:01:11 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2013-05-15 19:17:57 +1000
commit9a5ad65330693b3273972b63d10f2907d9ab954a (patch)
tree3717cb1f7b1373bc4a1d29a03739e7b275fc61e2 /render
parent35c2e263db01b2b61354298e5e85aa3cae8ac317 (diff)
Abstract cursor refcounting
Too many callers relied on the refcnt being handled correctly. Use a simple wrapper to handle that case. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to 'render')
-rw-r--r--render/animcur.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/render/animcur.c b/render/animcur.c
index 9cbba83fa..038c5b9be 100644
--- a/render/animcur.c
+++ b/render/animcur.c
@@ -383,8 +383,7 @@ AnimCursorCreate(CursorPtr *cursors, CARD32 *deltas, int ncursor,
ac->elts = (AnimCurElt *) (ac + 1);
for (i = 0; i < ncursor; i++) {
- cursors[i]->refcnt++;
- ac->elts[i].pCursor = cursors[i];
+ ac->elts[i].pCursor = RefCursor(cursors[i]);
ac->elts[i].delay = deltas[i];
}