[vlc-devel] [PATCH] freetype: remove unnecessary assert()

Salah-Eddin Shaban salshaaban at gmail.com
Mon Feb 2 12:13:55 CET 2015


VLC nightly builds (debug and release) on Windows are crashing on this
assert, with error messages like the ones in this thread:

http://stackoverflow.com/questions/13893122/q-assert-has-different-behavior-when-my-project-is-built-in-visual-studio-vs-qt

I get "This application has requested the Runtime to terminate it in
an unusual way", and when run under gdb "Invalid parameter passed to C
runtime function" just after the assert.

On my Windows build it does nothing. And on linux it also seems to do
nothing, even on debug builds. I'm not sure why that is.

On Mon, Feb 2, 2015 at 1:12 PM, Salah-Eddin Shaban <salshaaban at gmail.com> wrote:
> This assert() will fail when zero-width spaces are encountered and ignored.
> It would also fail when GetGlyph() returns an error.
> ---
>  modules/text_renderer/freetype.c | 1 -
>  1 file changed, 1 deletion(-)
>
> diff --git a/modules/text_renderer/freetype.c b/modules/text_renderer/freetype.c
> index 050ace6..8d314fe 100644
> --- a/modules/text_renderer/freetype.c
> +++ b/modules/text_renderer/freetype.c
> @@ -1520,7 +1520,6 @@ static int ProcessLines( filter_t *p_filter,
>                      break;
>                  }
>
> -                assert( p_line->i_character_count == i_index - i_start);
>                  p_line->p_character[p_line->i_character_count++] = (line_character_t){
>                      .p_glyph = (FT_BitmapGlyph)glyph,
>                      .p_outline = (FT_BitmapGlyph)outline,
> --
> 1.9.1
>



More information about the vlc-devel mailing list