# HG changeset patch # User ranma # Date 1294704740 0 # Node ID 3c1c3676df94217037e9e2b1593621559795a31e # Parent 2290be558d555df3abd64856aca2647889357280 Fix uCode memleak found by debian automated code analysis diff -r 2290be558d55 -r 3c1c3676df94 libvo/vo_dxr2.c --- a/libvo/vo_dxr2.c Tue Jan 11 00:09:59 2011 +0000 +++ b/libvo/vo_dxr2.c Tue Jan 11 00:12:20 2011 +0000 @@ -897,6 +897,7 @@ 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 @@ crop.arg4=0; ioctl(dxr2_fd, DXR2_IOC_SET_OVERLAY_CROPPING, &crop); } + + free(uCode); return 0; }