[MPlayer-cvslog] r32781 - trunk/libvo/vo_dxr2.c

ranma subversion at mplayerhq.hu
Tue Jan 11 01:12:21 CET 2011


Author: ranma
Date: Tue Jan 11 01:12:20 2011
New Revision: 32781

Log:
Fix uCode memleak found by debian automated code analysis

Modified:
   trunk/libvo/vo_dxr2.c

Modified: trunk/libvo/vo_dxr2.c
==============================================================================
--- trunk/libvo/vo_dxr2.c	Tue Jan 11 01:09:59 2011	(r32780)
+++ trunk/libvo/vo_dxr2.c	Tue Jan 11 01:12:20 2011	(r32781)
@@ -897,6 +897,7 @@ static int preinit(const char *arg) {
   if (read(uCodeFD, uCode+4, uCodeSize) != uCodeSize) {
 
     mp_msg(MSGT_VO,MSGL_ERR,"VO: [dxr2] Could not read uCode uCode: %s\n", strerror(errno));
+    free(uCode);
     return VO_ERROR;
   }
   close(uCodeFD);
@@ -916,6 +917,8 @@ static int preinit(const char *arg) {
     crop.arg4=0;
     ioctl(dxr2_fd, DXR2_IOC_SET_OVERLAY_CROPPING, &crop);
   }
+
+  free(uCode);
   return 0;
 }
 


More information about the MPlayer-cvslog mailing list