X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=modules%2Fcodec%2Ftelx.c;h=3e6a47756e0ab65b7b7dcfaa6557068c0be4c7ba;hb=9b19a07597165946cb8ec2d1753ad237963e4e6b;hp=455f4b9636ad47b14dd2c5a8fefb01c8830007a4;hpb=449fd28aaf007c6411251dae9d0dbfdc65b135d1;p=vlc diff --git a/modules/codec/telx.c b/modules/codec/telx.c index 455f4b9636..3e6a47756e 100644 --- a/modules/codec/telx.c +++ b/modules/codec/telx.c @@ -29,7 +29,8 @@ # include "config.h" #endif -#include +#include +#include #include #include @@ -68,7 +69,7 @@ static subpicture_t *Decode( decoder_t *, block_t ** ); "your subtitles don't appear.") vlc_module_begin(); - set_description( _("Teletext subtitles decoder") ); + set_description( N_("Teletext subtitles decoder") ); set_shortname( "Teletext" ); set_capability( "decoder", 50 ); set_category( CAT_INPUT ); @@ -182,10 +183,7 @@ static int Open( vlc_object_t *p_this ) p_dec->pf_decode_sub = Decode; p_sys = p_dec->p_sys = malloc( sizeof(decoder_sys_t) ); if( p_sys == NULL ) - { - msg_Err( p_dec, "out of memory" ); return VLC_ENOMEM; - } memset( p_sys, 0, sizeof(decoder_sys_t) ); @@ -455,8 +453,11 @@ static subpicture_t *Decode( decoder_t *p_dec, block_t **pp_block ) char psz_line[256]; int i, total; - if( pp_block == NULL || *pp_block == NULL ) return NULL; + if( pp_block == NULL || *pp_block == NULL ) + return NULL; p_block = *pp_block; + if( p_block->i_rate != 0 ) + p_block->i_length = p_block->i_length * p_block->i_rate / INPUT_RATE_DEFAULT; *pp_block = NULL; dbg((p_dec, "start of telx packet with header %2x\n",