Commit a3ad51e0 authored by Michael Niedermayer's avatar Michael Niedermayer

avfilter/af_amerge: avoid undefined shift (<<64) in outlayout setup

Fixes CID1322306
Reviewed-by: 's avatarGanesh Ajjanagadde <gajjanag@mit.edu>
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent 7eab904d
......@@ -110,8 +110,8 @@ static int query_formats(AVFilterContext *ctx)
for (i = 0; i < nb_ch; i++)
s->route[i] = i;
outlayout = av_get_default_channel_layout(nb_ch);
if (!outlayout)
outlayout = ((int64_t)1 << nb_ch) - 1;
if (!outlayout && nb_ch)
outlayout = 0xFFFFFFFFFFFFFFFFULL >> (64 - nb_ch);
} else {
int *route[SWR_CH_MAX];
int c, out_ch_number = 0;
......
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