Commit 80d7c4fb authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

packetizer: use date_Change()

See also 110e4f85.
parent 96e7e418
......@@ -427,11 +427,7 @@ static block_t *Packetize( decoder_t *p_dec, block_t **pp_block )
p_sys->mlp.i_channels, p_sys->mlp.i_rate );
if( p_sys->mlp.i_rate > 0 )
{
const mtime_t i_end_date = date_Get( &p_sys->end_date );
date_Init( &p_sys->end_date, p_sys->mlp.i_rate, 1 );
date_Set( &p_sys->end_date, i_end_date );
}
date_Change( &p_sys->end_date, p_sys->mlp.i_rate, 1 );
}
p_dec->fmt_out.audio.i_rate = p_sys->mlp.i_rate;
......
......@@ -967,10 +967,7 @@ static void SetupOutput(decoder_t *p_dec, block_t *p_block)
{
msg_Info(p_dec, "AAC channels: %d samplerate: %d",
p_sys->i_channels, p_sys->i_rate);
const mtime_t i_end_date = date_Get(&p_sys->end_date);
date_Init(&p_sys->end_date, p_sys->i_rate, 1);
date_Set(&p_sys->end_date, i_end_date);
date_Change(&p_sys->end_date, p_sys->i_rate, 1);
}
p_dec->fmt_out.audio.i_rate = p_sys->i_rate;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment