[vlc-devel] [PATCH 2/4] subpicture private data condition
Laurent Aimar
fenrir at elivagar.org
Fri Mar 25 14:59:12 CET 2011
On Fri, Mar 25, 2011 at 12:22:50AM +0200, Yuval Tze wrote:
> check that the private data is not null before accessing it.
> ---
> src/misc/subpicture.c | 10 +++++-----
> 1 files changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/src/misc/subpicture.c b/src/misc/subpicture.c
> index 3e84a27..a1ee386 100644
> --- a/src/misc/subpicture.c
> +++ b/src/misc/subpicture.c
> @@ -152,11 +152,11 @@ void subpicture_Update( subpicture_t *p_subpicture,
> if( !p_upd->pf_validate )
> return;
> if( !p_upd->pf_validate( p_subpicture,
> - !video_format_IsSimilar( p_fmt_src,
> - &p_private->src ), p_fmt_src,
> - !video_format_IsSimilar( p_fmt_dst,
> - &p_private->dst ), p_fmt_dst,
If p_upd->pf_validate is non NULL, then p_private cannot be NULL...
(due to the way subpicture_New() work).
So, this patch should not be needed at all.
--
fenrir
More information about the vlc-devel
mailing list