comparison aac.c @ 7889:fdd3e68dcf94 libavcodec

Cast the return value of get_bits() to signed integer such that the subtraction is conducted as a signed calculation. Patch by Alex Converse (alex converse gmail com)
author superdump
date Thu, 18 Sep 2008 15:35:08 +0000
parents 8277c41b7160
children 20dd4e5e5aa6
comparison
equal deleted inserted replaced
7888:d0489fa75c41 7889:fdd3e68dcf94
977 memset(coup, 0, sizeof(ChannelCoupling)); 977 memset(coup, 0, sizeof(ChannelCoupling));
978 return -1; 978 return -1;
979 } 979 }
980 980
981 sign = get_bits(gb, 1); 981 sign = get_bits(gb, 1);
982 scale = pow(2., pow(2., get_bits(gb, 2) - 3)); 982 scale = pow(2., pow(2., (int)get_bits(gb, 2) - 3));
983 983
984 if ((ret = decode_ics(ac, sce, gb, 0, 0))) 984 if ((ret = decode_ics(ac, sce, gb, 0, 0)))
985 return ret; 985 return ret;
986 986
987 for (c = 0; c < num_gain; c++) { 987 for (c = 0; c < num_gain; c++) {