summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRussell King <rmk+cubox@arm.linux.org.uk>2013-08-27 17:43:00 +0100
committerRussell King <rmk@arm.linux.org.uk>2013-10-29 19:21:09 +0000
commit86eda7716d28becc9ccdf552f4c840b615d68755 (patch)
tree1e499f3c90d6a475ab3236e7a777aad716d69001
parent7e9ef8cb983d37a1fc31dc7d75581c0aab4b8db2 (diff)
downloadxf86-video-armada-86eda7716d28becc9ccdf552f4c840b615d68755.tar.gz
xf86-video-armada-86eda7716d28becc9ccdf552f4c840b615d68755.tar.xz
Ensure that all DRM planes are freed on error
Take the array size on the array, not on something else. Signed-off-by: Russell King <rmk@arm.linux.org.uk>
-rw-r--r--src/armada_drm_xv.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/armada_drm_xv.c b/src/armada_drm_xv.c
index 3464442..e1b7afc 100644
--- a/src/armada_drm_xv.c
+++ b/src/armada_drm_xv.c
@@ -1090,7 +1090,7 @@ Bool armada_drm_XvInit(ScrnInfoPtr pScrn)
return TRUE;
err_free:
- for (i = 0; i < ARRAY_SIZE(drmxv->plane); i++)
+ for (i = 0; i < ARRAY_SIZE(drmxv->planes); i++)
if (drmxv->planes[i])
drmModeFreePlane(drmxv->planes[i]);
free(drmxv);