aacdec/lcg_random: fix harmless integer overflow

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
pull/28/head
Michael Niedermayer 13 years ago
parent 7ea5dbcb83
commit 386d60f978
  1. 2
      libavcodec/aacdec.c

@ -781,7 +781,7 @@ static int decode_audio_specific_config(AACContext *ac,
* *
* @return Returns a 32-bit pseudorandom integer * @return Returns a 32-bit pseudorandom integer
*/ */
static av_always_inline int lcg_random(int previous_val) static av_always_inline int lcg_random(unsigned previous_val)
{ {
return previous_val * 1664525 + 1013904223; return previous_val * 1664525 + 1013904223;
} }

Loading…
Cancel
Save