[vlc-devel] commit: access_pvr: fix potential memleak and factorize. ( Rémi Duraffort )

Rémi Denis-Courmont remi at remlab.net
Mon Mar 9 09:25:17 CET 2009


On Sun,  8 Mar 2009 23:08:27 +0100 (CET), git at videolan.org (git version
control) wrote:
> vlc | branch: master | Rémi Duraffort <ivoire at videolan.org> | Sun Mar  8
> 23:01:34 2009 +0100| [ebbf215befae1a06c01997e3dec720a7f428a84f] |
> committer: Rémi Duraffort 
> 
> +    p_sys->psz_videodev = var_CreateGetString( p_access, "pvr-device" );
> +    p_sys->psz_radiodev = var_CreateGetString( p_access,
> "pvr-radio-device" );
                             ^^^^^^^^^^^^^^^^^^^

>      /* parse command line options */
>      psz_tofree = strdup( p_access->psz_path );
>      if( !psz_tofree )
> -        return VLC_ENOMEM; /* <-- FIXME MEMORY LEAK */

The presence of this comment should have hinted that it was not so
trivial...

-- 
Rémi Denis-Courmont




More information about the vlc-devel mailing list