diff options
Diffstat (limited to 'apps/codecs')
-rw-r--r-- | apps/codecs/libwma/bitstream.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/apps/codecs/libwma/bitstream.c b/apps/codecs/libwma/bitstream.c index 12cf0518ee..bce7ee2ae6 100644 --- a/apps/codecs/libwma/bitstream.c +++ b/apps/codecs/libwma/bitstream.c | |||
@@ -119,7 +119,8 @@ static int build_table(VLC *vlc, int table_nb_bits, | |||
119 | const void *codes, int codes_wrap, int codes_size, | 119 | const void *codes, int codes_wrap, int codes_size, |
120 | uint32_t code_prefix, int n_prefix) | 120 | uint32_t code_prefix, int n_prefix) |
121 | { | 121 | { |
122 | int i, j, k, n, table_size, table_index, nb, n1, index, code_prefix2; | 122 | int i, j, k, n, table_size, table_index, nb, n1, index; |
123 | uint32_t code_prefix2; | ||
123 | uint32_t code; | 124 | uint32_t code; |
124 | int flags = 0; | 125 | int flags = 0; |
125 | VLC_TYPE (*table)[2]; | 126 | VLC_TYPE (*table)[2]; |
@@ -152,7 +153,7 @@ static int build_table(VLC *vlc, int table_nb_bits, | |||
152 | /* if code matches the prefix, it is in the table */ | 153 | /* if code matches the prefix, it is in the table */ |
153 | n -= n_prefix; | 154 | n -= n_prefix; |
154 | if(flags & INIT_VLC_LE) | 155 | if(flags & INIT_VLC_LE) |
155 | code_prefix2= code & (n_prefix>=32 ? 0xffffffff : (1 << n_prefix)-1); | 156 | code_prefix2= code & (n_prefix>=32 ? 0xffffffff : (uint32_t)( (1 << n_prefix)-1)); |
156 | else | 157 | else |
157 | code_prefix2= code >> n; | 158 | code_prefix2= code >> n; |
158 | if (n > 0 && code_prefix2 == code_prefix) { | 159 | if (n > 0 && code_prefix2 == code_prefix) { |