xf86XvMCScreenInit: Avoid leak if dixRegisterPrivateKey fails
authorAlan Coopersmith <alan.coopersmith@oracle.com>
Sun, 27 Jan 2013 22:00:54 +0000 (14:00 -0800)
committerAlan Coopersmith <alan.coopersmith@oracle.com>
Wed, 6 Feb 2013 02:34:57 +0000 (18:34 -0800)
commitb1129a1f1771c9d1653cc15aae94a614f081638a
tree5ff586fb7dcf024e1236166b35cb33effe1e2ffc
parent563db909bcf965b6103c1807bf9f00ede957077d
xf86XvMCScreenInit: Avoid leak if dixRegisterPrivateKey fails

Found by parfait 1.1 memory analyser:
   Memory leak of pointer 'pAdapt' allocated with malloc((88 * num_adaptors))
        at line 162 of hw/xfree86/common/xf86xvmc.c in function 'xf86XvMCScreenInit'.
          'pAdapt' allocated at line 158 with malloc((88 * num_adaptors)).

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
hw/xfree86/common/xf86xvmc.c